top of page

Search Results

255 items found for ""

  • Sine Wave Plot Program

    < Back Sine Wave Plot Program This program uses the lbar command to plot a sine wave. Program --- Plot a sine wave with the lbar command. --- prog_vars = d/run_no 0 d/angle 0.0 d/raw_sin 0.0 d/sin_value 0.0 prog_vars. prog_start = print "Plot a sine wave" prog_start. prog_loop = -- Calc sine of the abgle sin /angle -> /raw_sin -- Scale the Sine wave to fit. mapf -1 1 0 50 /raw_sin -> /sin_value -- Plot the sine wave. tbar * /sin_value 25 40 "Sine /angle = /sin_value" inc /angle 0.1 -- 0.1 best -- Check if we should exit. any /run_no > 100 -> exitprog inc /run_no prog_loop. prog_stop = print "Good bye" prog_stop.

  • Task Arguments Test

    < Back Task Arguments Test This is a test program for task arguments. Program --- Task Arguments Test Program --- prog_vars = d/count 0 d/begin_count 255 d/message "" prog_vars. prog_start = print "Prog Start" /count 0 /message "Fred and Dag" rdbg 7 lv prog_start. prog_loop = inc /count print "Run /count" -- Channel input @TEST -- print "Call Test Task2 Channel in" -- test_task2 /240 "Jack and Jill" -- Test task 1 print "" print "Call Test Task1 no in or out" test_task1 -- Test task 2 print "" print "Call Test Task2 in only" test_task2 123564 "Jack" print "FRED_DAG" test_task2 888 /message lv test_task5 123 123.456 print "Call Test Task2 in only RUN 2" test_task2 88 "Jack and Jill" print "Call Test Task2 in only RUN 3" test_task2 /count "Jack and Jill" -- System Varibale input print "Call Math Task1 Sys var in" maths_task1 /pi -- Test task 3 print "" print "Call Test Task3 out only" d/out1 0 d/out2 "" test_task3 -> /out1 /out2 print "" print "Task3 out1 [ /out1 ] out2 [ /out2 ]" print "Task3 direct o1 [ /output1 ] o2 [ /output2 ]" -- Test task 4 print "" print "Call Test Task4 in & out" /out1 0 /out2 "" test_task4 100 "Jack Penman" -> /out1 /out2 print "Task4 o1 [ /out1 ] o2 [ /out2 ]" print "Task4 direct o1 [ /output41 ] o2 [ /output42 ]" --- Deliberate Error Cases The following are dekoverately wrong. -- extra input arg. maths_task1 /pi "Jack and Jill" --- -- inc /count -- any /count > 10 -> exitprog exitprog prog_loop. test_task1 = -- task with no inputs or outputs print "test_task1 no in or out" test_task1. test_task2 /input1 1 /input2 "" = -- task with inputs only. print "test_task2 in1 /input1 in2 /input2" test_task2. test_task3 -> /output1 1 /output2 "" = -- task with outputs only. -- Set the output values. /output1 100 /output2 "Output no 2" print "test_task3 out1 [ /output1 ] out2 [ /output2 ]" test_task3. test_task4 /input41 1 /input42 "" -> /output41 1 /output42 "" = -- task with inputs and outputs. -- Set the output values. /output41 100 /output42 "Output no 2" print "test_task4 in1 [ /input41 ] in2 [ /input42 ]" print "test_task4 out1 [ /output41 ] out2 [ /output42 ]" test_task4. test_task5 /in51 0 /in52 0.0 = -- task with two numeric inputs. print "Task5 Integer input [ /in51 ] float in [ /in52 ]" test_task5. maths_task1 /mathin1 0.0 = print "Maths Task 1 input /mathin1" maths_task1. prog_stop = print "bye" prog_stop.

  • Plot Sine Wave on Show Page

    < Back Plot Sine Wave on Show Page This program plots a sine wave using the Show page. Program --- Store and Plot Sine Wave. Generate the values for a sine wave, store in an array and then plot them. --- prog_vars = d/point_no 0 d/current_angle 0.0 d/sine_value 0.0 d/plot_value 0 prog_vars. prog_start = pclear print "Plot a Sone wave" prog_start. prog_loop = plot_sine 100 0.0 exitnow prog_loop. plot_sine /no_of_points 0 /start_angle 0.0 = -- Generate the sine wave data points and plot them. print "Plot /no_of_points of Sine Wave" /current_angle /start_angle -- Loop through and plot the points repeat /no_of_points -> -- Calc the sine of the /current_angle sin /current_angle -> /sine_value -- Scale the Sine wave to fit. mapf -1 1 -50 50 /sine_value -> /plot_value plot 0 50 ^id=sine^w=500^h=200^xp=/point_no ^v1=/plot_value ^title=Sine Wave^ -- Next angle inc /current_angle 0.5 inc /point_no repeat. plot_sine. prog_stop = print "Good bye" prog_stop.

  • Projects

    Projects Automatic Night Light In this project, you will make use of the LDR sensor on the TOP to create a light-sensitive night light with one of the LEDs. Read More Driving Robot In this project, you will create a robot that can drive around using the DRIVE page on the dashboard, the command line, or a program. Read More Electronic Dice In this project, you will build on the Rainbow LED project by turning the JackBord into a dice. Using the random function to generate a number and assigning each LED a value (all 5 lit up represents six) makes a very simple electronic dice. Read More Rainbow LED Display In this project, you will utilise all five LEDs on the TOP to create a rainbow. With proper commands, you can even make it pulse in sequence. Read More Soccer Robot In this project, you will use your JackBord to play soccer! We do this by turning an ice cream container into a scoop or a foot so the JackBord can push a ball from one point to another. Read More WiFi Signal Dial In this project, we are going to turn the JackBord into a dial so we can visually see the strength of the WiFi signal it is currently receiving. We will use an RC servo, which will move its arm in response to the WiFi strength. Read More

  • Romeos Infrared Remote Control Driving Program

    < Back Romeos Infrared Remote Control Driving Program This program allows a JackBord to with drive motors to be driven using a normal TV remote control. Program --- Romeos Infrared Remote Control Driving Program 22 July 2021 This program allows a JackBord with drive motors to be driven using a normal TV remote control. --- prog_vars = d/count 0 d/color 0 d/pos 50 d/neg -50 prog_vars. prog_start = pclear stop -- Claw up and open svp c1 0 svp c2 180 print "Program Start neg /neg pos /pos" prog_start. prog_loop = -- pclear -- "/s_ird neg /neg pos /pos" -- Motion Control any /s_ird = 505 -> sbms /pos /pos any /s_ird = 481 -> sbms /pos /neg any /s_ird = 515 -> sbms /neg /neg any /s_ird = 527 -> sbms /neg /pos any /s_ird = 542 -> sbms 0 0 -- Claw control any /s_ird = 513 -> svp c1 0 any /s_ird = 541 -> svp c1 50 any /s_ird = 511 -> svp c2 0 any /s_ird = 418 -> svp c2 180 -- Speed Control any /s_ird = 517 -> /pos 40|/neg -40 any /s_ird = 519 -> /pos 60|/neg -60 inc /count any /count >= 5 -> rand 1 15 -> /color l1 /color rand 1 15 -> /color l2 /color rand 1 15 -> /color l3 /color /count 0 enda. prog_loop. prog_stop = bms 0 print "Bye" prog_stop.

  • Simple WiFi Signal

    < Back Simple WiFi Signal This program will display the Wifi signal strength received by the JackBord. it will do 100 runs and then stop. It uses the /s_wifisig system variable to get the Wifi signal strength. Program --- Simple Wifi Signal Program This program will display the Wifi signal strength received by the JackBord. it will do 100 runs and then stop. It uses the /s_wifisig system variable to get the Wifi signal strength. --- prog_vars = d/run_no 0 prog_vars. prog_start = "Wifi Signal Program" prog_start. prog_loop = -- Display the Wifi Signal Strength "Run /run_no Wifi signal /s_wifisig" -- Exit after 100 runs inc /run_no any /run_no >= 100 -> "Run /run_no Time to Exit" exitprog enda. prog_loop. prog_stop = print "Prog STOPPED!" prog_stop.

  • Detecting Collisions

    Detecting Collisions A simple way to detect collisions is to use a switch and the button press command. This allows you to have the robot react in a certain manner when it collides with or makes contact with an object or another robot. ​ Push buttons switches are common but a switch can also simply be two wires making contact as shown below. When the two copper wires make contact with a metallic object, such as another JackBord, the switch is closed and the btp command will take the specified action. ​ The two sections of copper are soldered to some wires which will connect to the JackBord. The white plastic in the middle is an insulator and serves as the mount point for the detector as shown below. ​ The command to use for detecting and counting the collisions is: btp a1 inc /crash1 This assumes the sensor is connected to port pin A1 and that we are using the /crash1 variable to count the collisions.

  • 404 Error Page | Jackbord

    Oops, this page isn't available. Sorry about that. It may still be a work in progress, or you may need to simply try again. Return Home

  • SPI Commands

    < Back SPI Commands spion - Enable the SPI system Purpose Turn on the SPI system. Syntax spion spioff - Disable the SPI system Purpose Turn off the SPI system. Syntax spioff spipins - Set the port pins to use for the SPI system Purpose Allows the pins to be used for the SPI system to be set. Syntax spipins SCK MISO MOSI CS Arguments SCK Port pin to be used for the SCK pin. MISO Port pin to be used for the MISO pin. MOSI Port pin to be used for the MOSI pin. CS Port pin to be used for the CS pin. Examples spipins c2 c3 c4 c5 Setup port C pins 2 to 5 to be the SPI port pins. Notes The port B and E pins cannot be used for SPI. spot - Set the Resistance value of the MCP4161 Digital Potentiometer Purpose Set the Resistance value of the MCP4161 Digital Potentiometer which is connected to the SPI port. Syntax spot value Arguments value Digital pot value between 0 and 255. Examples spot 50 Notes Connection to JackBord SPI Port on Port C. vspi - Display the status of the SPI system Purpose Displays the status and basic settings of the SPI port system. Syntax vspi

  • Any Statement Example

    < Back Any Statement Example In this example we check the value of /count against 10 and quit when /count is 10. Program -- Any example no 1 prog_vars = d/count 0 prog_vars. prog_start = print "Any example no 1" prog_start. prog_loop = inc /count print "Count /count" any /count >= 10 -> exitprog prog_loop. prog_stop = print "Bye" prog_stop.

  • Smart LED Random Flashing

    < Back Smart LED Random Flashing Smart LED Random Flashing Program This program has 6 WS2812B smart LEDs connected to port A pin a1. It will cycle the LEDs through random colors. Program --- Smart LED Random Flashing Program This program has 6 WS2812B smart LED's connected to port A pin a1. It will cycle the LEDs through random colors. --- prog_vars = d/led_no 0 d/red 0 d/green 0 d/blue 0 prog_vars. prog_start = print "Smart LED Program Started" -- turn all 6 leds off sled a1 6 0 /red /green /blue prog_start. prog_loop = -- Set each color to a random value rand 0 255 -> /red rand 0 255 -> /green rand 0 255 -> /blue -- Set the LEDs color -- /led_no is the LED we are setting. sled a1 6 /led_no /red /green /blue -- Inc to the next LED and then start again. any /led_no >= 6 -> /led_no 0 else inc /led_no enda. prog_loop. prog_stop = print "prog stopped" prog_stop.

  • Bumper Robot V2

    < Back Bumper Robot V2 This version of the bumper robot has a smart RGB LED strip fitted with 5 LEDs. There is a front and back bumper connected to pins a1 and a2 respectively. If the front bumper is triggered the robot will move backwards and the LEDs will start to flash from the front to the back indicating that the robot is moving backwards. If the back bumper is triggered the robot will start to move forward and the LEDs will flash from the back to the front to indicate the change in direction. Program --- Bumper Robot Program V2 --- prog_vars = -- Keep track of the number of bumps. d/front 0 d/back 0 -- Track to no of times we have run. d/count 0 d/speed 0 -- Direction timer d/dir_timer 0 d/dir 0 d/total_leds 5 d/led_no 0 d/red 0 d/green 0 d/blue 0 prog_vars. prog_start = print "Bumper Robot Program Setup" -- Reset the buttons rstb -- Setup the front bumper. -- Go back and turn left. btp c1 front_bump btp c2 back_bump bms 50 sledn 10 sledoff prog_start. prog_loop = -- main program loop -- Increase the /count by 1 inc /count /speed /150 -- Change dirtection if it gets stuck. any /dir_timer > 400 -> /dir_timer 0 tgdir enda. -- Set each color to a random value -- rand 0 255 -> /red -- rand 0 0 -> /green -- rand 0 255 -> /blue all /dir = 0 /led_no < 7 -> inc /led_no all /dir = 0 /led_no >= 7 -> /led_no 0 all /dir = 1 /led_no >= 1 -> dec /led_no all /dir = 1 /led_no <= 0 -> /led_no 7 -- "dir /dir /led_no" sled /led_no /red /green /blue prog_loop. front_bump = -- Task for front bumper -- Set each color to a random value rand 0 0 -> /red rand 0 255 -> /green rand 0 0 -> /blue bms -50 lms -10 d500 lms -50 inc /front /dir_timer 0 /dir 1 front_bump. back_bump = -- Task for the back bumper rand 0 255 -> /red rand 0 0 -> /green rand 0 0 -> /blue bms 50 rms 10 d500 rms 50 inc /back /dir_timer 0 /dir 0 back_bump. prog_stop = print "Bye Front /front Back /back" -- Clear the buttons rstb -- Stop the robot stop prog_stop.

  • Car Program with From Obsticle Avoidence

    < Back Car Program with From Obsticle Avoidence This is the basic program for a car with an infrared obsticle detection sensor mounted at the front. The sensor is the Infrared Proximity Obstacle Avoidance Sensor 2cm to 30cm which sends an infrared beam out the front and if this hits something it reflects back and is detected. This alerts the program to the fact there is an obstacle in the way of the Robot. in this case the front_hit task is called. When it detects an obsticle at the front it will stop, go back a little, turn and then move forwards again. It will keep on doing this until it gets out of the obsticles way. Program --- Car program with front obsticle avoidence. --- prog_vars = d/count 0 prog_vars. prog_start = -- Clear the screen pclear print "Program Start" -- Reset the buttons rstb -- USER LED off l1 0 -- Set sensor on pin a1 to call front_hit task if we collide. btp a1 front_hit -- Start moving at half speed bms 50 prog_start. prog_loop = inc /count prog_loop. front_hit = --- If the front sensor is triggered we need to stop, go back for a bit and then turn, so we don't hit the same thing again. Fianlly move forward again. --- -- USER on l1 1 -- Go backwards for 2 secs bms -50 dly 2000 -- Turn left turn -50 dly 2000 -- go forwards bms 50 -- USER off l1 0 front_hit. prog_stop = print "Bye" stop prog_stop.

  • Basic Soil Moisture Meter

    < Back Basic Soil Moisture Meter This program uses a capacitive soil moisture probe connected to pin a1 of the JackBord to measure the moisture in some soil and display the reading using the USER LED on the JackBord. The color of the LED will match the soil moisture reading as follows: >= 90% Green >= 75% Cyan >= 50% Navy >= 25% Orange >= 10% Magenta >= 0% Red Program --- Basic Soil Moiture Meter Program Get readings from the sensor on pin a1 and scale them between the min and max calibration values to get a reading between 0 and 100. Display them using the JackBords USER LED. That wy you dont need a web browser to use the meter. --- prog_vars = d/count 0 -- Calibration values d/min_value 6 d/max_value 56 -- The final soil moisture reading d/soil_moisture 0 d/moisture_color 0 prog_vars. prog_start = pclear print "Program Start" -- Setup the sensor on pin a1 gvr a1 100 0 prog_start. prog_loop = -- main program loop -- Get a fresh reading get_soil_moisture -- Update the USER LED's color display_moist_color /soil_moisture print "/count a1 /a1 Soil moisture /soil_moisture" -- Check if we have done 100 readings inc /count any /count >= 100 -> exitprog -- New reading every second d1000 prog_loop. get_soil_moisture = -- Get the reading from a1 and scale it mapi /min_value /max_value 0 100 /a1 -> /soil_moisture get_soil_moisture. display_moist_color /moisture 0 = -- Use ant command to shoose color to display. -- >= 90% Green -- >= 75% Cyan -- >= 50% Navy -- >= 25% Orange -- >= 10% Magenta -- >= 0% Red -- NO Reading Dim white ant /moisture -> >= 90 -> l1 8 >= 75 -> l1 12 >= 50 -> l1 13 >= 25 -> l1 5 >= 10 -> l1 14 >= 0 -> l1 3 -> l1 1 ant. display_moist_color. prog_stop = print "Bye" prog_stop.

  • Projects - Electronic Dice

    < Back Electronic Dice In this project, you will build on the Rainbow LED project by turning the JackBord into a dice. Using the random function to generate a number and assigning each LED a value (all 5 lit up represents six) makes a very simple electronic dice. Just like the Rainbow LED Display project, we use the same circuit and connect the TOP LEDs to Port A on the JackBord. This time we control the LEDs via a program rather than the command line. This means that we don’t have to manually enter commands every time we want the LEDs to light up, but the program also allows us to give the LEDs a practical function which is, in this case, giving a number between 1 and 6. PDF INSTRUCTIONS Project Gallery

  • Advanced Mine

    < Back Advanced Mine This program assumes that the mines trigger switches are on pins A2 & A3. When one of the switches is triggered we will either add or remove health from the robot. The RGB LEDs are connected to Port C: RED C1 GREEN C2 BLUE C3 The color values for the /color variable are: The port C values say which port C pin will be on for a given color. Color no 0 off 1 Red. C1 2 Green C2 3 Blue C3 4 Cyan C2 C3 5 Purple. C1 C3 6 Yellow C1 C2 Program --- Advanced Mine Program --- prog_vars = d/triggers 0 d/health 10 d/trig_result 0 d/flashes 0 d/start_time 0 d/run_time 0 prog_vars. prog_start = "Mine Start" /start_time /uptime -- Setup the trigger for pin A2 & A3 btp a2 do_boom btp a3 do_boom prog_start. prog_loop = -- Calc run time sub /uptime /start_time -> /run_time -- Check if we are dead >>>>>>>>>>> any /health <= 0 -> -- Dead "XXXXXX WE DIED XXXXX" repeat 10 -> tg c1|d50 exitprog enda. -- Exit any /triggers > 10 -> exitprog any /run_time >= 60 -> "Time up"|exitprog prog_loop. do_boom = --- The mine is triggered work out the health or damage. --- /flashes 0 -- Get a new random number between -6 and 6. rand -6 6 -> /trig_result -- Update the health var add /health /trig_result -> /health -- Check for negative health, if so flash 4 times. any /trig_result < 0 -> /flashes 4 inc /triggers print "Trig /triggers TR /trig_result Health /health flash /flashes" set_color /health /flashes do_boom. set_color /color 0 /led_flash 0 = --- Colors 0 off 1 Red 2 Green 3 Blue 4 Cyan c2 c3 on 5 Magenta c1 c3 6 . Yellow c1 c2 --- -- All c off coff -- Get abs version of color abs /color -> /color repeat /led_flash -> -- Set the color on Port C ant /color -> = 1 -> c1 1 = 2 -> c2 1 = 3 -> c3 1 = 4 -> c3 1|c4 1 = 5 -> c1 1|c3 1 = 6 -> c1 1|c2 1 -> c1 1|c2 1 ant. d250 -- any /led_flash > 2 -> d250 -- any /led_flash < 2 -> d1000 coff repeat. set_color. prog_stop = print "Bye" -- clear the buttons rstb prog_stop.

  • Plot a Cos Wave

    < Back Plot a Cos Wave This program uses the plot command to graph a cos wave. Program --- Plot a cos wave with the plot command. --- prog_vars = d/run_no 0 d/angle 0.0 d/Xpos 0 d/raw_cos 0.0 d/cos_value 0.0 prog_vars. prog_start = pclear ptl 10 0 ^ts=24^tc=blue^ "Plot a Cos wave" prog_start. prog_loop = -- Calc cost of the abgle cos /angle -> /raw_cos -- Scale the Cos wave to fit. mapf -1 1 0 50 /raw_cos -> /cos_value -- Plot the Cos wave. plot 10 50 ^t1n=COS^xdp=100^xp=/Xpos^v1=/cos_value^ inc /angle 0.1 -- 0.1 best inc /Xpos -- Check if we should exit. any /run_no > 100 -> exitprog inc /run_no prog_loop. prog_stop = print "Good bye" prog_stop.

  • Gallery

    Funding Our mission is for JackBord to be the notebook equivalent for STEM subjects in all schools Our early adopter schools have identified the efficiency of the JackBord as being the key item in their teaching toolkit and are setting aside budget to purchase more. We understand some schools may have fully allocated budgets, or simply struggle for sufficient funding to undertake anything other than traditional education, often not enough for many students to achieve curriculum or realise potential; especially those with special needs or where traditional learning fails to trigger their interest. Here are some ideas for schools to consider to fund a system that could make a difference to them and their students. The JackBord Trust Visit Website JackBord Works Limited's main shareholder is a registered charity, the JackBord Trust. ​ The Trust's primary purpose is to find ways to reach and encourage more students to take up coding, engineering and science as careers through educational advancement. ​ The Trust could assist schools and students to find ways to fund its purpose through the purchase and or donation of JackBords from any dividends from its shareholding in the business, or as a vehicle for businesses, parents and other charities to make a tax deductible donation.

  • MK1-S1 Ultrasonic Ruler

    < Back MK1-S1 Ultrasonic Ruler This is the code for the MK1-S1 Ultrasonic Ruler project. It displays the distance to an object in cm on the Show page. Program --- MK1-S1 Ultrasonic Ruler Program For Me-Kit project MK1-S1 Ultrasonic Ruler Displays the distance to an object in cm on the Show page. --- prog_vars = d/count 0 prog_vars. prog_start = pclear -- Show title ptl 10 0 ^ts=35^ "MK1-S1 Ultrasonic Ruler" ptl 40 180 "999 = out of range." -- Quit button pb 10 70 ^n=Quit^p=exitprog^ -- Setup the ultrasonic radar on port C. uradar c1 c2 prog_start. prog_loop = -- main program loop -- Display the distance reading in cm ptl 40 120 ^ts=40^tc=blue^ "Distance /35 cm" -- Wait 100ms d100 prog_loop. prog_stop = ptl 10 0 ^ts=35^ "Bye" prog_stop.

  • PWM Commands

    < Back PWM Commands lpwc - List the PWM system channel allocations Purpose List the PWM channel allocations on the esp32. The esp32 can handle a maximum of 6 pwm chans. Syntax lpwc lpwi - List the PWM system settings info Purpose Display the settings being used by the PWM system. Syntax lpwi mfreq - Set PWM freq for the Drive Motors Purpose This sets the pwm frequency for the main drive motors. NOTE: the updated freq gets picked up by the relevant functions. Syntax mfreq freq Arguments freq The frequency to use for the pwm main drive system. 50 to 5000Hz. pfreq - Set PWM freq for the I/O Ports Purpose This sets the pwm freq for the pwm command. Syntax pfreq freq Arguments freq The frequency to use for the pwm system. 50 to 5000Hz. pwm - Pulse width modulation on a pin Purpose pwm allows a pulse width modulated (PWM) signal to be applied to a pin. Syntax pwm #~ duty Arguments #~ The port letter a, b, c, d and pin number 1 to 5. eg a1 or c4 duty The duty cycle from 0 to 100. Pushers No Returns Nothing Examples pwm a1 50 Set pin a1 at 50% pwm d1 75 Set the USER LED at 75% brightness pwm a3 /speed Use the /speed variable to set the pwm duty on pin a3

bottom of page