This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <WiFi.h> | |
#include <HTTPClient.h> | |
#include <Seeed_Arduino_SSCMA.h> | |
#include <Grove_LED_Bar.h> | |
//change to your ssid and password | |
const char* ssid = "Wifi SSID"; | |
const char* password = "Wifi Password"; | |
//change to your token and chatid |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import time | |
import board | |
import busio | |
import wifi | |
import socketpool | |
import ipaddress | |
import avoid_obstacles | |
import keep_distance | |
import line_tracking | |
from BPI_PicoW_S3_Car import Motor, Servo, I2CPCF8574Interface, LCD, LCD1602 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Thanks to this configuration for the initial legwork https://github.com/kbx81/esphome-configs/blob/main/dev/esp-funhouse.yaml | |
esphome: | |
name: funhouse | |
friendly_name: Funhouse | |
platformio_options: | |
board_build.mcu: esp32s2 | |
board_build.variant: esp32s2 | |
esp32: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
0: ELYOIECBAQK | |
1: FMCVJFDZNUD | |
2: QNKSLGECQVE | |
3: LQXAMTNDUTF | |
4: UUDBNHJEFRG | |
5: VPECQIQFVOH | |
6: WKFDUJUGWSI | |
7: XTPEVLVHXAJ | |
8: IOGFWMWIZBL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
VQEDSXMRTKSKNZZGSXNLBOEWGSOFFFAVWMJGBWHYASLIVNNUHNIZEDISSNBXTOYINIAGIENBQFBVUNNQUYQNKSQLOAMTVNPPM - 0 - CHILIAST | |
DNRPIFLIPZICMQGVOWMJATQJFIHHOESFMGTIAZWWSIFDUCVXGELXRNXOOEAWPTRHILSILDVAVYAUQCVNWRNMZODKTJDGUCYUE - 1 - CHILIAST | |
CEKFLEJHYXLZDGFFTVDBSPDZULJYHDOEESPDSQZJOLOPQBMQFHFWKCKTTHSVYPNGHOIDFNMSDRSQNBMMMKMLXTCYPMGIQBRXQ - 2 - CHILIAST | |
BHZHFDIGRWFXGVEEPUGEIYCRWOTRJNTDQIYPIGGZTOHFNALNUDOVZBUPPDIUEYVVGTLPOCLOCKINMALLEZDJWPBWYGCDNANQV - 3 - CHILIAST | |
LDXYONXVKVOWCXQDYQCALRBIMTPKTCPCVLEFLVFRPTJHMSJMWCHUXAHUYCLQRRMFFPFFHBJTBZLMDSJKQXGBVYAJRSBPMSVND - 4 - CHILIAST | |
ACWRHCKFZUHVBFDCRNBSFKAHEPYCPBYBDORHFXEIYPTYDOILMBJQWSWXRBFNKKLEUFOHJAIPLXFLGOIYVWCEURSZKIAFDOMMC - 5 - CHILIAST | |
SBVKJBUEXQJUAECBKEAOOMSGQFEZYARACTKYOFQHRFPRGTXKEATNVOZQKAOMZMJDWYHYTSXUAWOJCTXWDVBAQKORZLSHGTLLB - 6 - CHILIAST | |
OAUCTAHDJNTQSDBAZHSTHUOVVYRXESNSBPZRHEDGKYYKCPKYQJPMUTGNZJHLXUICMRJRPOKXSVHBBPKJCUASNMTIXOIYCPJKL - 7 - CHILIAST | |
TJQZPSWCNEPNINASXDIGJLTFDRKWROVOLFXKJDCVZRECBYUWVMYLQPFMXMJJWLXBEKTKYTUQOUJEAYUZBQSOMUPHJTLRBYIYA - 8 - CHILIAST | |
PMNXYOZ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ENGLISH_INDEX_OF_COINCIDENCE = 1.73 | |
def kasiski_examination(text) | |
segments = [] | |
(0..text.length-3).each do |starting_index| | |
segments += text[starting_index..-1].chars.each_slice(3).map(&:join) | |
end | |
segments.uniq! | |
# Only segments of length 3 should be kept (for the partial segments included) | |
segments.keep_if{|segment| segment.length == 3} |