Commit Graph

39 Commits (5c05d506bb83124f31bd55d5dcbdebbd070114fe)

Author SHA1 Message Date
David Montero Crespo dc5dfb8635 feat: enhance simulation accuracy and component interactions across various modules 2026-03-20 17:11:12 -03:00
David Montero Crespo f6fdae6b0e feat: enhance DHT22 and HC-SR04 simulations with cycle-accurate pin changes 2026-03-19 08:22:36 -03:00
David Montero Crespo 8ba11800e1 feat: add SensorControlPanel for interactive sensor controls
- Implemented SensorControlPanel component to allow real-time adjustments of sensor values during simulation.
- Introduced SensorUpdateRegistry for communication between UI and simulation.
- Added configuration for various sensors including sliders and buttons for user interaction.
- Enhanced existing sensor parts to support updates from SensorControlPanel.
- Created CSS styles for the SensorControlPanel layout and controls.
2026-03-19 01:52:46 -03:00
David Montero Crespo 220346f220 feat: enhance ESP32 emulation with SYSTIMER and interrupt handling, update GPIO pin mapping for power/GND 2026-03-17 10:08:06 -03:00
David Montero Crespo c19a6cb848 feat: update PWM handling in SimulatorCanvas and enhance I2C Scanner example with SSD1306 OLED integration 2026-03-16 22:15:52 -03:00
David Montero Crespo d35ad2d2f7 Refactor code structure for improved readability and maintainability 2026-03-16 18:31:46 -03:00
David Montero Crespo 20ccd87d1b feat: enhance ESP32 emulation with GPIO mapping and ADC support 2026-03-16 13:11:59 -03:00
David Montero Crespo bc31ee76c1 feat: enhance oscilloscope and simulator functionality
- Added `onPinStateChange` method to `ChipParts` for handling pin state changes in 7-segment displays.
- Updated `useOscilloscopeStore` to allow independent monitoring of multiple boards by adding `boardId` to channels and modifying `addChannel` method.
- Modified `getOscilloscopeCallback` in `useSimulatorStore` to filter channels based on `boardId` and pin number.
- Adjusted component and board position calculations in `useSimulatorStore` to account for wrapper offsets.
- Updated submodule references for `qemu-lcgamboa`, `rp2040js`, and `wokwi-elements` to indicate dirty states.
2026-03-16 10:31:02 -03:00
David Montero Crespo 7ab0f132a3 feat: add visual components for ATtiny85, Raspberry Pi Pico W, and RISC-V Board
- Implemented ATtiny85 visual component with DIP-8 layout and built-in LED.
- Added Raspberry Pi Pico W web component using official SVG and pin mapping.
- Created RISC-V Board visual component with SOP-20 style and built-in LED.
- Introduced RiscVCore class for minimal RV32I ISA interpreter with memory model.
- Developed RiscVSimulator class for CH32V003-compatible simulator with UART and GPIO support.
- Updated subproject commits for qemu-lcgamboa, rp2040js, and wokwi-elements to dirty state.
2026-03-15 15:39:26 -03:00
David Montero Crespo c69094e7d7 feat: Implement Virtual File System for Raspberry Pi 3 with context menu and upload functionality
- Add VirtualFileSystem component for managing files and directories.
- Integrate useVfsStore for state management of the virtual file system.
- Implement context menu for file operations: New File, New Folder, Rename, Delete.
- Add upload functionality to send files to Raspberry Pi.
- Create default file structure for new Raspberry Pi boards.
- Enhance editor with board-aware features and compile/run orchestration.
- Introduce CompileAllProgress component for tracking compilation status across boards.
- Redesign SerialMonitor to support multiple boards with tabbed interface.
- Establish Raspberry Pi specific workspace with terminal and file system integration.
2026-03-15 14:04:01 -03:00
David Montero Crespo fe89d06787 feat: implement segment dragging functionality in simulator canvas 2026-03-14 23:09:32 -03:00
David Montero Crespo 405ff1f017 Refactor wire management and rendering logic
- Updated wire structure to replace control points with waypoints for better handling of wire paths.
- Introduced new utility functions for wire hit detection and rendering segments.
- Enhanced wire creation process to support dynamic waypoints and color assignment.
- Implemented a new ESP32 worker for improved simulation handling.
- Added utility functions for generating orthogonal paths and auto-coloring wires based on pin names.
- Improved compatibility with existing projects by ensuring backward compatibility with wire data structures.
2026-03-14 22:55:13 -03:00
David Montero Crespo b0b3a8763d V1 feat: Enhance ESP32 emulation support and logging
- Added detailed logging for GPIO changes, system events, and errors in simulation websocket.
- Improved ESP32 firmware handling by merging individual binaries into a single 4MB flash image.
- Updated ESP32 bridge to handle serial output and GPIO changes with appropriate logging.
- Introduced integration test for ESP32 emulation, covering compilation, WebSocket connection, and event handling.
- Enhanced examples to include ESP32 projects and updated the examples gallery to reflect new board types.
- Refactored simulator store to manage ESP32 bridge and simulator instances more effectively.
- Updated requirements to include esptool for ESP32 firmware management.
2026-03-14 16:57:22 -03:00
David Montero Crespo 4a7c9e2e55 feat: enhance ESP32 emulation with GPIO pinmap and improved QEMU initialization handling 2026-03-14 12:05:35 -03:00
David Montero Crespo dc03c28fff feat: Enhance ESP32 support in simulator and QEMU management 2026-03-13 22:55:37 -03:00
David Montero Crespo 17b1a0f058 feat: add board types and mappings for Raspberry Pi 3B
- Introduced new BoardKind types for Raspberry Pi 3B and updated BoardInstance interface.
- Added BOARD_KIND_LABELS and BOARD_KIND_FQBN mappings for new board types.
- Implemented physical to BCM GPIO mapping for Raspberry Pi 3B in boardPinMapping utility.
- Updated BOARD_COMPONENT_IDS to include Raspberry Pi 3B.
- Enhanced isBoardComponent function to support new board type.
- Modified boardPinToNumber function to handle pin mapping for Raspberry Pi 3B.
2026-03-12 23:39:04 -03:00
David Montero Crespo b89f85e5f7 Merge branch 'feat/raspberryPi_emuation' of https://github.com/davidmonterocrespo24/wokwi_clon into feat/raspberryPi_emuation 2026-03-12 08:26:56 -03:00
David Montero Crespo 13997ff491 feat: add documentation page and Arduino serial integration test
- Created a new DocsPage component for project documentation with links to GitHub and Discord.
- Added Arduino sketch for serial communication test between Raspberry Pi and Arduino.
- Implemented avr_runner.js to emulate ATmega328P and bridge serial communication over TCP.
- Developed a Python test script to validate the serial integration between the emulated Raspberry Pi and Arduino.
2026-03-12 08:17:29 -03:00
copilot-swe-agent[bot] ad0656b1cc feat: add built-in oscilloscope / logic analyzer panel
- Add useOscilloscopeStore with ring-buffer sample storage and channel management
- Add onPinChangeWithTime callback to AVRSimulator (fires on every bit transition with cycle-derived timestamp)
- Add onPinChangeWithTime callback to RP2040Simulator (fires on GPIO state change)
- Wire oscilloscope callbacks in useSimulatorStore (initSimulator + setBoardType)
- Create Oscilloscope React component with canvas-based waveform rendering
- Add oscilloscope panel to EditorPage (resizable bottom panel, same as SerialMonitor)
- Add 'Scope' toggle button to SimulatorCanvas toolbar

Co-authored-by: davidmonterocrespo24 <47928504+davidmonterocrespo24@users.noreply.github.com>
2026-03-11 15:09:24 +00:00
copilot-swe-agent[bot] ad67e88320 feat: add mobile touch support to simulator canvas
- Single-finger pan on empty canvas background
- Single-finger drag for components and board
- Two-finger pinch-to-zoom centered on pinch midpoint
- Tap to open property dialog / deselect on mobile
- Add touch-action: none CSS to prevent browser scroll conflicts
- Add data-board-overlay attribute for touch target detection

Co-authored-by: davidmonterocrespo24 <47928504+davidmonterocrespo24@users.noreply.github.com>
2026-03-11 02:38:15 +00:00
David Montero Crespo 1018609ed4 feat: add Arduino Mega support to simulator
- Introduced ArduinoMega component for rendering in the simulator.
- Updated SimulatorCanvas to handle Arduino Mega board type.
- Enhanced AVRSimulator to support ATmega2560 architecture, including PWM pin mapping and port management.
- Modified PinManager to accommodate Mega's non-linear pin mapping.
- Updated boardPinMapping utility to include Mega analog pins.
- Adjusted Wokwi import/export functionality to recognize and handle Arduino Mega.
- Updated useSimulatorStore to initialize AVRSimulator with the correct board variant.
2026-03-09 10:08:14 -03:00
David Montero Crespo e488bed0df fix: remove clamping on board and component position updates for smoother dragging 2026-03-08 16:35:37 -03:00
David Montero Crespo 1206a34e64 feat: implement auto-pan feature for board visibility after project load and normalize pin names for component connections 2026-03-08 16:30:49 -03:00
David Montero Crespo 41dfd20583 feat: Add Arduino Nano support to simulator and update related components 2026-03-07 23:14:33 -03:00
David Montero Crespo f2b275c03d feat: Enhance board positioning by integrating boardPosition state in export/import functions and updating component dragging logic 2026-03-07 19:29:23 -03:00
David Montero Crespo 2744b398e3 feat: add zoom and pan functionality with wheel listener in SimulatorCanvas 2026-03-07 02:08:20 -03:00
David Montero Crespo 3ace72d0f8 feat: implement pan and zoom functionality in simulator canvas 2026-03-07 02:00:56 -03:00
David Montero Crespo c1fc653de2 feat: update component styles and add serial monitor functionality 2026-03-06 10:24:03 -03:00
David Montero Crespo 96131e7451 feat: add wrapper offset props to PinOverlay component for customizable positioning 2026-03-05 21:19:23 -03:00
David Montero Crespo 4ba2ccb877 Refactor simulator store to unify serial data handling and add board pin mapping utility
- Simplified serial data handling in `useSimulatorStore` for both AVR and RP2040 simulators.
- Introduced `boardPinMapping.ts` to map wokwi-element pin names to simulator GPIO/pin numbers for Arduino Uno and Nano RP2040.
- Added `compilationLogger.ts` to parse compile results into structured log entries for better console output.
2026-03-05 21:07:03 -03:00
David Montero Crespo efd4c11e03 feat: add ILI9341 TFT display simulation and enhance component registry loading 2026-03-05 01:52:15 -03:00
David Montero Crespo 426c7ab35f feat: establish initial simulator and editor environment with component rendering, wiring, library management, and backend services. 2026-03-04 22:05:23 -03:00
David Montero Crespo 7944ce2de3 feat: add support for RP2040 board, including simulator and compilation enhancements 2026-03-04 19:28:33 -03:00
David Montero Crespo c2f07665b4 feat: add react-router-dom for routing and enhance wire rendering with automatic offsets 2026-03-04 18:03:54 -03:00
David Montero Crespo ef7e86bc1e feat: Enhance simulator with new components and event handling
- Updated components-metadata.json with new generation timestamp.
- Added event handling for button presses and releases in DynamicComponent.
- Improved ExamplesGallery with new styles for placeholders and previews.
- Introduced LCD 20x4 display example with corresponding code and wiring.
- Enhanced SimulatorCanvas to subscribe components to pin changes.
- Implemented PartSimulationRegistry for managing component simulation logic.
- Added basic and complex parts simulation including pushbuttons, LEDs, and LCDs.
- Created utility functions for capturing canvas previews and generating SVG previews for example projects.
2026-03-04 13:36:33 -03:00
David Montero Crespo 217736c7cd feat: update architecture documentation and improve component property dialog 2026-03-03 20:42:17 -03:00
David Montero Crespo 8b1a402caf feat: add component metadata types and generator
- Created a new TypeScript file for component metadata types defining structure for dynamically loaded components.
- Implemented a metadata generator script that scans the wokwi-elements repository to extract component information, including properties and categories.
- Added package.json and package-lock.json for dependency management, including TypeScript and related tools.
- Introduced a new file to log ping statistics for testing purposes.
2026-03-03 19:30:25 -03:00
David Montero Crespo 46bccde953 Add backend and frontend test suites for Arduino compilation and simulation
- Implemented a comprehensive backend test suite in `test_compilation.py` to validate the Arduino CLI installation, AVR core presence, compilation service, and API endpoint functionality.
- Created a frontend test suite in `simulation.test.ts` to test the `PinManager` and `AVRSimulator` components, ensuring proper functionality and integration.
- Introduced new components for wire management in the simulator, including `PinOverlay`, `WireInProgressRenderer`, `WireLayer`, and `WireRenderer`, enhancing the visual wiring system.
- Developed utility functions for pin position calculations and wire color management, ensuring accurate connections and visual representation.
- Added types for wire management in `wire.ts`, defining structures for wire endpoints, control points, and signal types.
2026-03-03 16:44:07 -03:00
David Montero Crespo a8c4f143af feat: Implement Arduino Simulator with component management and simulation features
- Added SimulatorCanvas component for rendering the simulator interface.
- Integrated Wokwi components (Arduino, LED, Resistor, Pushbutton, Potentiometer) into the simulator.
- Created PinManager to handle pin state changes and notifications.
- Developed AVRSimulator class for emulating Arduino Uno functionality.
- Implemented hex file loading and compilation service.
- Added CSS styles for the simulator interface.
- Established Zustand stores for managing editor and simulator states.
- Created utility functions for parsing Intel HEX format.
- Set up Vite configuration for the frontend project.
- Added batch scripts for starting backend and frontend servers, and updating Wokwi libraries.
2026-03-03 00:20:49 -03:00