Quick update here! I have uploaded the final Haptic Sleeve Testing Program and documentation to Github. The testing program allows us to programmatically send commands to the Haptic Sleeve and log input from the user.
The full documentation for the code is located in the readme here! The readme contains all the steps to setup your environment before running the testing program.
To find the Bluetooth mac address of your ESP32, see this link for Windows. Additionally, you can run the code below on your ESP to get the MAC address through uPyCraft:
import network #network library to wirelessly access things
import ubinascii #to decode the mac address
station = network.WLAN(network.STA_IF)#declare station interface
station.active(True) #activate the interface
station.connect("D2D4B4", "L2C26C2C10656")#only connects to 2.4GHz
if(station.isconnected()):
print("Station connected!")
print('network config:', station.ifconfig()) # Print IP address
# ifconfig is linux eqvt to ipconfig for windows
print('MAC address:', station.config('mac')) #original form
mac = ubinascii.hexlify(station.config('mac'),':').decode()
print('MAC address (decoded):', mac)
# The last two lines are used to print out the mac address
Double check: Your computer's Bluetooth is enabled and is able to discover the ESP32 named "Haptic Sleeve" (or a different name if you changed the device name).
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.