Skip to content

one-for-all/furuta-sim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Furuta Pendulum Simulation from Arduino -> Physics

This project shows how you can build an entire robot in simulation, and code it in Arduino to test and verify your design.

alt text

Getting Started

Prerequisite

  1. Clone the gorilla-physics and avr8rs project to the same parent directory as this project.

  2. Build the gorilla-physics visualization typescript lib:

  • cd gorilla-physics/www
  • npm install rimraf and npm install typescript
  • npm run build and npm run build:lib

Run the simulation

change directory to www:

cd www

(install rimraf: npm install rimraf)

and then run the project (i.e. the local dev server):

npm run start

A browser tab should open and show the robot moving.

Update the Arduino code for the simulation

update the arduino/furuta/furuta.ino file as you wish.

Compile the Arduino code:

./build.sh furuta

Now the simulation should be running the updated controller code.

References

Substack post detailing the project.

This project depends on the following two projects:

Arduino simulator that runs the Arduino code: AVR8rs

Physics engine that simulates the robot: Gorilla Physics

About

Furuta pendulum simulation from Arduino all the way to physics

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published