author
67Instructables1,169,192Views305CommentsAustralia

Tell us about yourself!

Achievements

100+ Comments Earned a bronze medal
1M+ Views Earned a silver medal
Age of Aquariums Contest
Contest Winner Third Prize in the Age of Aquariums Contest
  • Cheap NMEA/AIS Hub -- RS232 to Wifi Bridge for Onboard Use

    The simple way is to hard code your wlan SSID and PW into the code when you build it.And at the same time set all the other parameters your need and then skip the webpage startup.Private msg me if you need help with this.

    View Instructable »
    • Stepper Speed Control Menu Driven for Arduino
      154 views
      4 favorites
      0 comments
    • Cheap NMEA/AIS Hub -- RS232 to Wifi Bridge for Onboard Use
      52 views
      1 favorites
      0 comments
  • Very Low Power BLE Made Easy With Arduino -- Part 1

    Ok back to tried and true debugging method.Remove come until is starts working, see Debugging Low Power above for checking if the loop is waking up.Then put code back in a little bit at a time to isolate the problem code.E.g. leave out the SPI code and LCD hardware and support code, but put in the calculation/handling code that works to prepare the data.Add back the SPI begin() end() but without the hardware and don't send any data. Then send some dummy data (without the LCD hardware/library)Keep adding stuff back in in small steps to find the problem.

    View Instructable »
  • Very Low Power BLE Made Easy With Arduino -- Part 1

    I have not used the SPI bus in the low power / sleep mode.Suggest you stop / shutdown the SPI bus completely between accessing the LCD

    View Instructable »
  • Coding Timers and Delays in Arduino

    Hi cedrix00,You can have three separate millisdelays, each with their own time setting, and control the calls accordingly.See Step 4 in https://www.instructables.com/Simple-Multi-task...for an example of this.If you are still having trouble, message me directly.

    View Instructable »
  • Coding Timers and Delays in Arduino

    :-( Good catch. Thanks for that.Fixed that now. Website was correct https://www.forward.com.au/pfod/ArduinoProgramming...

    View Instructable »
    • Arduino NANO 33 Made Easy BLE, Sense and IoT
      49 views
      0 favorites
      0 comments
  • Very Low Power BLE Made Easy With Arduino -- Part 1

    Hi,>>4. I generate .Hex file, send to the phone, and I am able to upload as "application" with the nRF connect App. It also asks for a .dat file, but it can upload th .hex fileSorry cannot help with this as I have never tried to PROGRAM the nRF51 via an Android mobile (OTA over the air). As that requires a special program to be running on the BLE chip and adds another level of complexity I can do without. As shown in this instructable, all my programming is done direct to an nRF52 (not an nRF51) chip via a programmer.Suggest give up on trying to program from your Android mobile and purchase some nRF52 chips (which have more memory) and try programming as described above.

    View Instructable »
  • Arduino String Manipulation Using Minimal Ram

    There is now a SafeString Arduino library available in the library manager that allows you to strictly limit the amount of memory your 'strings' use.see How to Use Strings in Arduino for BeginnersSafeString solves the problems of Arduino strings. SafeString never causes the sketch to reboot, never fragments the heap and includes detailed error checking and debugging messages

    View Instructable »
  • How to Use Strings in Arduino for Beginners

    Thanks to Va_Tech_EE, SafeString is now available to be installed via the Arduino Library Manager

    View Instructable »
  • How to Use Strings in Arduino for Beginners

    No just on my website (which is much older then github)Full source code is there in the ziphttps://www.forward.com.au/pfod/ArduinoProgramming/SafeString/index.html

    No just on my website (which has been around much longer then github)Full source code is there in the ziphttps://www.forward.com.au/pfod/ArduinoProgramming/SafeString/index.htmlFeel free to re-host it on GitHub. Just include a link and acknowledgement to the webpage above.

    View Instructable »
    • Arduino String Processing for Beginners
      90 views
      1 favorites
      0 comments
  • Large Stepper Motor Control A4988

    Nice intro to stepper motors, but the code is not very useful. Using delay() is evil as it blocks the rest of the sketch from running.The problem with the example sketch is that it does not let you control the stepper motor speed or position or enter commands to set the position or speed while the motor is running.Simple Multitasking in Arduinohttps://www.instructables.com/Simple-Multi-task... has an example sketch using AccelStepper library that runs the stepper and still leaves the sketch free to do other tasksArduino String Processing for Beginnershttps://www.instructables.com/Arduino-String-Pr...has an example sketch that shows you how to you can processes user commands while still running the rest of the sketch at maximum speed.Combining these two instructables with your great intro …

    see more »

    Nice intro to stepper motors, but the code is not very useful. Using delay() is evil as it blocks the rest of the sketch from running.The problem with the example sketch is that it does not let you control the stepper motor speed or position or enter commands to set the position or speed while the motor is running.Simple Multitasking in Arduinohttps://www.instructables.com/Simple-Multi-task... has an example sketch using AccelStepper library that runs the stepper and still leaves the sketch free to do other tasksArduino String Processing for Beginnershttps://www.instructables.com/Arduino-String-Pr...has an example sketch that shows you how to you can processes user commands while still running the rest of the sketch at maximum speed.Combining these two instructables with your great intro to stepper motors will give you a stepper motor controller that can be controlled on the fly by the user or other external inputs

    View Instructable »
  • Simple Multitasking in Arduino on Any Board

    Thanks. Keep an eye out for the SafeStrings tutorial I am working on at the moment.

    View Instructable »
    • Simple Arduino Libraries for Beginners
      160 views
      1 favorites
      0 comments
  • Coding Timers and Delays in Arduino

    millisDelay certainly does not block, but whatever you are doing in the justFinished() might block or elsewhere in the code, could be blocking. SD card access can block. Also Serial.print can blockTry adding a loopTimer() to get a better idea of what delays there are.from Simple Multitasking in Arduino on Any Boardhttps://www.instructables.com/Simple-Multi-task...also see that instructable for non-blocking Serial I/O

    View Instructable »
  • Simple Multitasking in Arduino on Any Board

    Would you like to private message me with some sample code?

    View Instructable »
  • Very Low Power BLE Made Easy With Arduino -- Part 1

    Sorry no, only one connection at a time, but you are correct you can set up more then one connection and 'switch' between them by disconnecting and choosing another connection

    View Instructable »
  • Simple WiFi to BLE (Bluetooth Low Energy) Bridge

    Sure, it should be possible, but I have not do it myself.You could start with nRF Connect android apphttps://play.google.com/store/apps/details?id=no.n... and https://github.com/NordicSemiconductor/Android-nRF-Connect and use it to scan for your devices and then find out which services and characteristics they use and relay those.

    Well BLE is a mess. Every different device/service has its own characteristics so you would need to have special code to handle and repeat each one. I have not checked, but I suspect that the smart watches and lights etc define their own custom services so you would first need to discover what those were and then connect receive and re-transmit them.So in short not easy to do.

    View Instructable »
  • Very Low Power BLE Made Easy With Arduino -- Part 1

    sounds good, msg me and we can take this off-line until it is fixed

    Looks like you are deeper in this than I needed to be. As you have probably already discovered, this project setup (compile/link) assumes there is a softdevice pre-loaded. If you load another hex that does not need a softdevice it may/will overwrite the exiting pre-loaded softdevice and so you will need to re-load the softdevice again when going back to this projects build process.Since you are using OpenOCD for debugging, how about putting together a short tutorial on using OpenOCD in debug mode to single step Arduino sketches?

    If you are not using either Particle Debugger or BlackMagic programmer, I cannot be of much help as those are the only ones I have experience with.The support for the other programmers was supplied by sandeepmistry so perhaps he can help you.Not sure what you mean by 'manually' flash. Arduino produces a hex file so you could just compile/download with not board attached and then find hex file that Arduino produced and manually flash it.

    View Instructable »
  • Very Low Power BLE Made Easy With Arduino -- Part 1

    See my fuller reply, but for programming via SWDIO and SWDCLK see the bottom of https://learn.sparkfun.com/tutorials/nrf52832-breakout-board-hookup-guide

    I think you are saying that you can flash a simple blink example. Can you flash that from an Arduino sketch?Are you first flashing the softdevice?I have not tried using ST-Link JTAG programmer or the Sparkfun board only the BlackMagic and Particle Programmer and the Redbead Nano V2, the SkyLab and GT832E_01 boards. If you are still having problems I suggest you start by following the instructable exactly using the Particle Debugger and one of the boards mentioned and get that working. Then try changing one part, e.g. start with changing the programmer and see that you can get that working. Then finally change the board. Note the Sparkfun board has different Arduino pin mappings from any of the other boards so you may have to create a new board for it See part 3 of this set of 3 ins…

    see more »

    I think you are saying that you can flash a simple blink example. Can you flash that from an Arduino sketch?Are you first flashing the softdevice?I have not tried using ST-Link JTAG programmer or the Sparkfun board only the BlackMagic and Particle Programmer and the Redbead Nano V2, the SkyLab and GT832E_01 boards. If you are still having problems I suggest you start by following the instructable exactly using the Particle Debugger and one of the boards mentioned and get that working. Then try changing one part, e.g. start with changing the programmer and see that you can get that working. Then finally change the board. Note the Sparkfun board has different Arduino pin mappings from any of the other boards so you may have to create a new board for it See part 3 of this set of 3 instructables.Looking at the Sparkfun schematic, programming is via TP1/TP2 and gnd, and the LED is on P_07 which in the Nano board pin mapping is called D8 in Arduino. Also in the NanoV2 board definition the LED_BUILTIN is set to 13 (D13 == P_011) and so will not flash the sparkfin led. Also on the NanoV2 tx/rx is P_29/P_30 while the SparkFun board uses P_27/P-26 You will need to define a new board definition for the SparkFun board.When you get that far start the TX/RX so you can debug the sketch.

    View Instructable »
  • Custom BLE – No Programming Required

    Update 9th January 2020 – Add note for installing RFduino support now that the company website is gone

    View Instructable »
  • Very Low Power BLE Made Easy With Arduino -- Part 1

    I can think of two problems, i) Sparkfun is using the sandeepmistry code base ii) Sparkfun has a boot loader installed on the chipeither or both of these could be stopping sleep from working.This instructable uses a modified and expanded version of sandeepmistry's code base and does not use a bootloader program on the chip.Be aware that if you follow these instructable you will a) need a real programmer as described aboveb) loose the convenience of Sparkfuns programming methodc) need to add support for this board to code used in this project, seehttps://www.forward.com.au/pfod/BLE/LowPower/NanoR...or https://www.instructables.com/Easy-Very-Low-Pow...

    View Instructable »
  • Very Low Power BLE Made Easy With Arduino -- Part 1

    The important output is loop() woke up at .. what does that say?

    Connect a uart Blink_lp_timer.ino outputs print each time it wakes up, so check it only wakes up as shown above.

    View Instructable »
  • Very Low Power BLE Made Easy With Arduino -- Part 1

    two things come to mind.i) the UART draws mAs if started, even if nothing is connectedii) the the loop is not actually stopped. try the Blink_lp_debug.ino sketch (above) and see how long your loop is asleep(and the current drain with the UART running.)

    View Instructable »
  • Simple Multitasking in Arduino on Any Board

    Update 21st Nov 2019 - Added comparison examples for Arduino_FreeRTOS and frt compared to Simple Multi-tasking in Arduino

    View Instructable »
  • Simple Multitasking in Arduino on Any Board

    You seem to have the right idea.Well, in these cases you often need to turn the code inside out.That is bring the low level calls up to the top level and use a 'state' variable to keep track of where you are up to.Multitasking is about doing a little bit of a lot of things in sequence so that is appears a lot of things are happening at the same time.Handling the Avoidance will get messy so ideally you would put all the code in its own files Avoidance.cpp and Advoidance.h files in the same directory as your robot sketch .ino file.Here I will just assume all the code is in the main .ino sketch and all the variables are globals.copy this code the the IDE and reformat it.// Create some states to keep track of what Avoidance is doing// this would be a good place to use C enums// but for simpli…

    see more »

    You seem to have the right idea.Well, in these cases you often need to turn the code inside out.That is bring the low level calls up to the top level and use a 'state' variable to keep track of where you are up to.Multitasking is about doing a little bit of a lot of things in sequence so that is appears a lot of things are happening at the same time.Handling the Avoidance will get messy so ideally you would put all the code in its own files Avoidance.cpp and Advoidance.h files in the same directory as your robot sketch .ino file.Here I will just assume all the code is in the main .ino sketch and all the variables are globals.copy this code the the IDE and reformat it.// Create some states to keep track of what Avoidance is doing// this would be a good place to use C enums// but for simplicity/clarity, I am using the equivalent ints// the possible statesconst int AvoidanceIdle = 0;const int AvoidanceStart = 1;const int AvoidanceHaveResult = 2;const int AvoidanceRight = 3;const int AvoidanceFront = 4;const int AvoidanceLeft = 5;int AvoidanceState = AvoidanceIdle; // state variable initially idlemillisDelay servoMovementDelay;unsigned long SERVO_MOVEMENT_DELAY_MS = 600;void startAvoidance() { // set the start state if (AvoidanceState != AvoidanceIdle) { return; // already running } // else AvoidanceState == AvoidanceStart;}void startServoMove(int angle_to_look) { ServoEyes.write (angle_to_look); // start servo servoMovementDelay.start(SERVO_MOVEMENT_DELAY_MS); // start delay to tell us when it is finished // if you remember the last angle of the servo you can use that // to reduce the delay needed here based on angle to move}int getRange() { int range = eyes.Ranging(CM); // this call takes average of 20ms // see if you can change library to start call and come back // here later to get results // would need another AvoidanceState number to keep track of this return range;}int calculateNewDirection() { // ... return newDirection;}void goInNewDirection() { // change direction}void doAvoidanceCycle() { if (AvoidanceState == AvoidanceIdle) { return; // nothing to do return quickly } // else what are we up to // you could use a switch statement here particularly if using enums // but if else works as well if (AvoidanceState == AvoidanceStart) { // start finding range Front AvoidanceState = AvoidanceFront; startServoMove(C_Fangle); // start servo return; // nothing to do until servo get there } else if (AvoidanceState == AvoidanceFront) { if (servoMovementDelay.justFinished()) { rangeFront = getRange(); // this call takes average of 20ms // try next direction AvoidanceState = AvoidanceLeft; startServoMove(C_Langle); // start servo return; // nothing to do until servo get there } else { return; // still waiting for servo } } else if (AvoidanceState == AvoidanceLeft) { if (servoMovementDelay.justFinished()) { rangeLeft = getRange(); // this call takes average of 20ms // try next direction AvoidanceState = AvoidanceRight; startServoMove(C_Rangle); // start servo // if you remember the last angle of the servo you can use that // to reduce the delay needed here based on angle to move return; // nothing to do until servo get there } else { return; // still waiting for servo } } else if (AvoidanceState == AvoidanceRight) { if (servoMovementDelay.justFinished()) { rangeRight = getRange(); // this call takes average of 20ms newDirection = calculateNewDirection(); AvoidanceState = AvoidanceHaveResult; return; // main loop picks up newDirection and resets state to Idle } else { return; // still waiting for servo } } // else should not get here!!}//The main loop() would bevoid loop() { doAvoidanceCycle(); // call this every loop to check on millisDelay if (AvoidanceState == AvoidanceHaveResult) { // last call got new result // pick up new direction newDirection = newDirection; AvoidanceState = AvoidanceIdle; // go back to idle goInNewDirection(); } if (stuck) { // need to start avoidance again startAvoidance(); }}

    View Instructable »
  • Coding Timers and Delays in Arduino

    That is off topic here, email or msg me.

    I think you wanted to vary the delays so perhapsdelay(i*1000) instead.Delays are evil, but you won't notice that until you try and do something else as well as turn the leds on and off.

    View Instructable »
  • Coding Timers and Delays in Arduino

    There a couple of ways to do this. One uses just one millisDelay and keeps track of the relay state On/Off. A simplier approach is to use two millisDelays, one for the On and one for Off.Copy and paste the following code into Arduino and reformat it.// // flash led on Uno -- 6sec on and 30sec off using millisDelay#include <millisDelay.h>const int Led_pin = 13; millisDelay LedOnDelay;const unsigned long LED_ON_DELAY_MS = 6*1000; // 6 x 1000mS = 6secmillisDelay LedOffDelay;const unsigned long LED_OFF_DELAY_MS = 30*1000; // 30 x 1000mS = 30secvoid setup() { // put your setup code here, to run once: pinMode(Led_pin, OUTPUT); // set led output // note some relay boards are active HIGH and some active LOW // start with led ON digitalWrite(Led_pin, HIGH); // turn led On LedOnDel…

    see more »

    There a couple of ways to do this. One uses just one millisDelay and keeps track of the relay state On/Off. A simplier approach is to use two millisDelays, one for the On and one for Off.Copy and paste the following code into Arduino and reformat it.// // flash led on Uno -- 6sec on and 30sec off using millisDelay#include <millisDelay.h>const int Led_pin = 13; millisDelay LedOnDelay;const unsigned long LED_ON_DELAY_MS = 6*1000; // 6 x 1000mS = 6secmillisDelay LedOffDelay;const unsigned long LED_OFF_DELAY_MS = 30*1000; // 30 x 1000mS = 30secvoid setup() { // put your setup code here, to run once: pinMode(Led_pin, OUTPUT); // set led output // note some relay boards are active HIGH and some active LOW // start with led ON digitalWrite(Led_pin, HIGH); // turn led On LedOnDelay.start(LED_ON_DELAY_MS); // start delay}void loop() { // put your main code here, to run repeatedly: // check which timer has just finished if (LedOnDelay.justFinished()) { // turn led off and start offDelay digitalWrite(Led_pin, LOW); // turn led Off LedOffDelay.start(LED_OFF_DELAY_MS); } if (LedOffDelay.justFinished()) { // turn led on and start onDelay digitalWrite(Led_pin, HIGH); // turn led On LedOnDelay.start(LED_ON_DELAY_MS); } // other code here runs every loop}

    View Instructable »
  • Simple Multi-tasking in Arduino on Any Board

    Updated Supplies to include full list of software/libraries used in this instructable.

    Unfortunately your definition of multi-tasking is not accurate, you only need one core. see https://en.wikipedia.org/wiki/Computer_multitaskin..."Multitasking does not require parallel execution of multiple tasks at exactly the same time."The time management needs a deep knowledge of the microcontroller and its interrupts.The aim of this instructable was to avoid having a deep knowledge and to avoid completely using interrupts. The loopTime is used here to gives you the insight you need to develop a practical, useful program.As the title says this is 'simple' multi-tasking which avoids the complexities and board limitations of an RTOS system.

    View Instructable »
    • Simple Multi-tasking in Arduino on Any Board
      2,271 views
      11 favorites
      10 comments
  • Simple Multi-tasking in Arduino on Any Board

    I have made a few suggestions to Arduino over the years, but nothing has ever come of it :-(

    p.s. I updated the instructable to explicitly mention downloading and installing both the loopTimer and millisDelay. No reason to make it more difficult than it is. Happy to hear if you have any other comments.all the bestmatthew

    View Instructable »
  • Simple Multi-tasking in Arduino on Any Board

    loopTimer depends on millisDelay, so you need to install both the loopTimer.zip and millisDelay.zip libraries. Step 2 has been updated to make this clearer.

    Step 2 has the paragraph -- "The loopTimer library provides a simple timer that keeps track of the maximum and average time it take to run the loop code. Download the zip file and use Arduino IDE menu Sketch -> Include Library -> Add.ZIP library to add it in. Insert #include "loopTimer.h" at the top of the file and then add loopTimer.check(&Serial); to the top of your loop() method. The loopTime library uses millisDelay library so you need to install that as well."Installing millisDelay library should get you going. Get back to me if you have any other problems

    View Instructable »
  • Simple Multi-tasking in Arduino on Any Board

    Thanks for that catch. Let me know if you find any other typos

    View Instructable »
  • Coding Timers and Delays in Arduino

    5th Sept 2019 update:Removing delay() calls is the first step to achieving simple multi-tasking on any Arduino board. The instructable Simple Multi-tasking in Arduino on Any Board covers all the other necessary steps.

    View Instructable »
  • Update: 7th April 2019 – Rev 3 of lp_BLE_TempHumidity, adds Date/Time plots, using pfodApp V3.0.362+, and auto throttling when sending data

    View Instructable »
  • Update: 7th April 2019 – Rev 3 of lp_BLE_TempHumidity, adds Date/Time plots, using pfodApp V3.0.362+, and auto throttling when sending data

    View Instructable »
  • 5th May 2019 update:Renamed isFinished() to justFinished(), as it only returns TRUE once just after the delay finishes.Added Freeze/Pause delay example

    View Instructable »
    • Arduino Date/Time Plotting/Logging Using Millis() and PfodApp
      219 views
      5 favorites
      1 comments
  • Update 26th April 2019 -- added section on How to avoid the 49.7day millis() limit and why you should not

    View Instructable »
  • Update 23rd April 2019 -- For date/time plots using only Arduino millis() see Arduino Date/Time Plotting/Logging Using Millis() and PfodApp The latest free pfodDesigner V3.0.3610+ generated complete Arduino sketches to plot data against date/time using Arduino millis() NO Android or Arduino CODING IS REQUIRED

    View Instructable »
  • Update 23rd April 2019 -- For date/time plots using only Arduino millis() see Arduino Date/Time Plotting/Logging Using Millis() and PfodApp The latest free pfodDesigner V3.0.3610+ generated complete Arduino sketches to plot data against date/time using Arduino millis() NO Android or Arduino CODING IS REQUIRED

    View Instructable »
  • Update 23rd April 2019 -- For date/time plots using only Arduino millis() see Arduino Date/Time Plotting/Logging Using Millis() and PfodApp The latest free pfodDesigner V3.0.3610+ generated complete Arduino sketches to plot data against date/time using Arduino millis() NO Android or Arduino CODING IS REQUIRED

    View Instructable »
  • Yes, using my pfodApp, Android app, you can download the historical (saved) data to your phone by pressing one of the buttons. That data is logged to a file on your mobile and also displayed as a plot. You can also view the raw data on your mobile.Later you can transfer the data file to your computer.In other of my projects, the device continually sends measurements while it is connected, which you can choose to plot. see https://www.instructables.com/Adafruit-Feather-...for example. I am currently working on adding the ability to plot date/time as well.As with all things pfod, the device controls every thing.The device will supply the date and time as part of the data being sent. since the mobile cannot tell, itself, when the device actually took the measurements.

    Yes, using my pfodApp, Android app, you can download the historical (saved) data to your phone by pressing one of the buttons. That data is logged to a file on your mobile and also displayed as a plot. You can also view the raw data on your mobile.Later you can transfer the data file to your computer.In other of my projects, the device continually sends measurements while it is connected, which you can choose to plot. see https://www.instructables.com/Adafruit-Feather-...for example.I am currently working on adding the ability to plot date/time as well.As with all things pfod, the device controls every thing.The device will supply the date and time as part of the data being sent. since the mobile cannot tell, itself, when the device actually took the measurements.

    Instructables mucks up the code examples. Download the code files to see the clean code.

    View Instructable »
  • Instructables mucks up the code examples. Download the code files to see the clean code.

    Those files are in the cores sub-directory of the hardware directory in the zip file. Email me at pfod.com.au via support if you need more help.

    View Instructable »
  • .... here "sometimes something happens" starts and takes itself some X (unidentified) seconds, so FlashDelay should be freezed-in (note : in every loop X is different).Every loop runs hundreds of times per sec so not sure what you mean by "in every loop X is different" since if you are 'freezing' the flasher one loop, it will not be finished by the next loop. Can we take this off-line until we sort it out? Private message me or email me at pfod.com.au via support.

    The trick is to use remaining() BEFORE you 'freeze' the delay to capture how much of the delay is left to run and then start the delay again later for the remaining time. See the attached code image for an example.NOTE: If you add print statements, they take time to print so start/stop the delays before printing any debug info

    One user had trouble with this library because they forgot that delay.isFinished() only returns true ONCE, just when the delay expires. delay.isRunning() lets you know if the delay is still running.However in hindsight I can see why the user might think isFinished() is the same as not isRunning()So the question is "Do you have suggestions for an alternative name for isFinished()"?for example perhaps delay.hasJustFinished() or some such.

    View Instructable »
  • Updated 19th March 2019 to fix link to code zip

    View Instructable »
  • Added Part 2 of this Instructable, Part 2 -- Temperature/Humidity Monitorhttps://www.instructables.com/Easy-Very-Low-Pow...which includes tuning BLE parameters for low power.

    View Instructable »
  • Added note on nRF52 Low Power Optimizations under Measuring the Supply Currenta) enabling the nRF52 DC to DC converter and b) disabling the Serial UARTto reduce supply current.

    View Instructable »
  • Added note on, Issue with NRF51 unexpectedly entering debug mode, under Measuring the Supply Current

    View Instructable »
    • Coding Timers and Delays in Arduino
      148 views
      0 favorites
      1 comments
  • I have posted a more detailed instructable about avoiding Arduino delays() CODING TIMERS AND DELAYS IN ARDUINOhttps://www.instructables.com/Coding-Timers-and... It explains why you need to use (millis() - time) and includes a simple library that does the logic for you, millisDelay.Also covers repeating timers and stopping delays before they expire.

    View Instructable »
  • That should not be too difficult. You need a BLE server to connect to, linked via Serial to a WiFi client. Lots of ESP8266 client examples available, e.g. see the examples that come with the Arduino install.As for the BLE server, suggest you start with the free pfodDesigner app and create a minimal menu, generate the code and then just use the BLE Uart parts to extract your message. see https://www.forward.com.au/pfod/BLE/ and for ESP32 BLE and WiFi see https://www.forward.com.au/pfod/ESP32/ for completed code examples.One thing to be careful of is when to close, on both ends, the WiFi link. I normally do that with an idle timeout, then you need to add an auto-reconnect when new data (a new connection) arrives. I am currently working on a WiFi/BLE/Bluetooth to LoRa bridge for extr…

    see more »

    That should not be too difficult. You need a BLE server to connect to, linked via Serial to a WiFi client. Lots of ESP8266 client examples available, e.g. see the examples that come with the Arduino install.As for the BLE server, suggest you start with the free pfodDesigner app and create a minimal menu, generate the code and then just use the BLE Uart parts to extract your message. see https://www.forward.com.au/pfod/BLE/ and for ESP32 BLE and WiFi see https://www.forward.com.au/pfod/ESP32/ for completed code examples.One thing to be careful of is when to close, on both ends, the WiFi link. I normally do that with an idle timeout, then you need to add an auto-reconnect when new data (a new connection) arrives. I am currently working on a WiFi/BLE/Bluetooth to LoRa bridge for extra range.

    Edit: I missed the point about using a commercial app. In that case the problem is finding out and coding the BLE services and characteristics that the app expects to see. You will need some detailed technical information on that.

    View Instructable »
  • I don't use App Inventor so could not say. However BLE does NOT have a standard 'uart' connection defined so you will have to make your own. In the above project the code generator, generates code for a 'Nordic uart BLE connection' the Nordic Semiconductor uses for their apps. In pfodApp is coded the corresponding client to match. Since the code generated for the Feather nrF52 is Nordic Uart compatible, you can also use their apps to connect to it, Such as Nordic nRF Connect and Nordic nRF UART v2.0 apps in google play.

    View Instructable »
  • Update: 13th July 2018 - added 3-terminal regulator to toroid supply

    View Instructable »
  • Update 6th July 2018 : A 3G/2G version of this project, using SIM5320, is available here

    View Instructable »
  • Out of ideas here also. According to http://www.electrodragon.com/product/esp-12f-esp82... the ESP-12F is just a repackaged version of the ESP-01 with more pinouts and so should work just like my ESP-01 here. Are you using the blink sketch to test?

    View Instructable »
  • You need pullups, as shown in steps 3 and 4 above for the ESP8266 to restart and run your sketch. BUT you need to ground GPIO0 when power is applied (or reset released) to get into programming mode.

    View Instructable »
  • I had a closer look at the ESP8266-01 that I used in ESP8266-01 Wifi Shield(https://www.forward.com.au/pfod/CheapWifiShield/ESP2866_01_WiFi_Shield/index.html)Just after the module powers up there is 50mS of 2.5kHz oscillations before the GPIO0 settles HIGH (due to the 3K3 external pullup resistor)Using the ESP8266 Arduino addon V2.4.1, I programmed that board with the standard Arduino IDE blink example with this code changeint led = 0;i.e. driving GPIO0 on the ESP8266 and got a clean square wave output.So using GPIO0 for an output works fine for my ESP8266-01. I don't have a ESP8266-12F to test (which has more pins so less need to use GPIO0) So I don't know what the problem is with your chip.Some possibilities arei) it is continually rebooting and you are seeing the startup oscillationsi…

    see more »

    I had a closer look at the ESP8266-01 that I used in ESP8266-01 Wifi Shield(https://www.forward.com.au/pfod/CheapWifiShield/ESP2866_01_WiFi_Shield/index.html)Just after the module powers up there is 50mS of 2.5kHz oscillations before the GPIO0 settles HIGH (due to the 3K3 external pullup resistor)Using the ESP8266 Arduino addon V2.4.1, I programmed that board with the standard Arduino IDE blink example with this code changeint led = 0;i.e. driving GPIO0 on the ESP8266 and got a clean square wave output.So using GPIO0 for an output works fine for my ESP8266-01. I don't have a ESP8266-12F to test (which has more pins so less need to use GPIO0) So I don't know what the problem is with your chip.Some possibilities arei) it is continually rebooting and you are seeing the startup oscillationsii) you grounded the GPIO0 for reprogramming while the GPIO0 was still being driven high and low and so shorted out the GPIO0 output and damaged the chipThe safe way to reprogram the ESP8266 when your code drives the GPIO0 output is to a) Power down the boardb) short GPIO0 to gndc) power up the board which goes into program mode due to the short on GPIO0d) remove the short from GPIO0 so you don't short out the output when the program runse) reprogram the boardf) power cycle the board if necessary.Please report back here if you get you board to work

    View Instructable »
  • Added ESP8266-01 on-board leds and resistors to the circuits. You can control these leds from the pins they are attached to.

    View Instructable »