Skip to main content

Release 32

Release 32 introduces a number of new features to impOS™, but focuses more on fixes and improvements, of which there are many. The most important new features are a major increase in the volume of Squirrel code that can be stored on the device, and the incorporation of a new impOS upgrade mechanism.

Thanks to changes made to the device-side virtual machine and the server-side bytecode compiler, we have improved the way Squirrel code is stored on the imp. With release 32, you will get approximately double the space for code on the imp without making any source changes. In other words, when transferring your code to a device, the IDE will report that your software takes up around half the storage it did under impOS Release 30. Increased data compression will result in more free RAM too.

Meanwhile, the new upgrader is not only faster than before, but also more reliable and better able to cope with bad network connections and blocked HTTP ports. The upshot: a significantly quicker and more robust upgrade process. Note that the upgrade to release 32 is obviously performed with the code already in the imp, so the upgrade improvements will only be visible on the next OS release.

Other New Features


  • We have a new BlinkUp LED code to more clearly indicate that the device has successfully received the transmitted WiFi network and Electric Imp Cloud enrollment credentials: three seconds of solid green, instead of the quick green blip that previous versions showed. Note that even during the solid green, the imp is continuing to run so this may hide the red/amber codes seen during the start of a connection - so the imp may appear to go directly from solid green to slow green flash.
  • As before, a BlinkUp will reboot the device. This is now indicated to the squirrel code with a new wake reason constant, WAKEREASON_BLINKUP.


  • The UART buffers through which data passes in and out of the imp can now be resized, the better to tune the UART to volume of data flow your application expects. Each buffer can be resized independently of the other.
  • Callback functions executed when data is being sent from the UART TX buffer (specified in uart.configure() can now be set to be called when the buffer is half empty, allowing your app to prepare the next batch of data to transmit to prevent under-runs.
  • Considerably improved UART transfer speeds when using Baud rates above ~250K — a result of the half-empty callback.


  • Developers building battery powered imp003-based products can now read the module’s VBAT pin voltage and get the battery voltage of the battery attached to VBAT (which may be a backup cell) rather than the VCC supplying the CPU as provided by the existing API call, hardware.voltage()

Bug Fixes

In addition to a variety of new features and enhanced or updated functionality, impOS release 32 addresses a number of bugs.


  • The imp’s LED now correctly signals a failure to connect after a warm boot.
  • Devices have been prevented from flashing the wrong LED signal when they disconnect.


  • Improved imp.wakeup() accuracy over long wake-up periods.
  • Fixed an issue where especially complex regular expressions could cause Squirrel to crash.
  • Prevent recursive calls to Squirrel’s function method call() and array method sort() from crashing the device.
  • Sending an empty blob from the agent to the device no longer crashes the device.


  • I²C reads of more than two bytes at a time no longer fail with some peripherals.
  • The I²C driver can now successfully handle attempts to write to a peripheral without supplying data.


  • The UART READ_READY flag is now level-triggered, not edge-triggered so callbacks are triggered consistently.
  • UART RX FIFO over-runs no longer cause the device to restart.

Sampler and FFDAC

  • The sampler now correctly returns a partially filled buffer (if one exists) after being told to stop sampling.
  • Attempts to resize sampler and fixedfrequencydac buffers while they are in flight are now blocked. If conversion is stopped, buffers can be resized and conversion then restarted.

WiFi and Networking

  • imp.scanwifinetworks() now pauses if a scan is being made by the device itself, preventing a crash-causing conflict between the two.
  • An imp.scanwifinetworks() memory leak has been plugged.
  • Joining a WiFi network should now take place more quickly, especially on networks with WMM enabled.
  • When a device fails to connect, it now makes a robust attempt to reconnect in environments with multiple access-points.
  • Server connection errors are now correctly relayed after timeouts.
  • The imp’s connection-attempt timeout counter is correctly reset after BlinkUp.
  • 32-character SSIDs are now handled correctly.
  • Assorted DHCP and DNS sub-system fixes have been applied.


  • The imp003’s microsecond timer no longer runs fast when the system clocks are lowered.
  • The wake-up pin’s automatic internal pulldown is now correctly cleared on wake-up.
  • The ‘don’t put the device into deep sleep outside idle-time handlers’ warning is now correctly sent after a post-sleep warm boot.
  • Squirrel code is now run immediately after a warm start when that start follows a reconfiguration of the device by BlinkUp.

Improvements Made During the Public Beta Period

  • Further upgrader reliability improvements.
  • TCP stack fixes.
  • DNS improvements and fixes.
  • Better WiFi join event handling (quicker joins in some cases).
  • Many corner case reconnect issues addressed.
  • Faster detection of low-voltage states (for flash timing adjustments).
  • Lower memory use when sending deep tables.
  • Improved memory arena handling and bug fixes.

New impOS API Methods




Updated impOS API Methods