Wednesday 13 December 2017

Fx options theta


Opcje Grecy: Theta Risk and Reward Czas zaniku wartości. tak zwany cichy zabójca nabywców opcji, może wytrzeć uśmiech z twarzy każdego zdeterminowanego przedsiębiorcy, gdy jego podstępna natura stanie się w pełni odczuwalna. Nabywcy z definicji mają tylko ograniczone ryzyko w swoich strategiach wraz z możliwością nieograniczonych zysków. Choć może to wyglądać dobrze na papierze, w praktyce często okazuje się, że to śmierć na tysiąc kawałków. Innymi słowy, prawdą jest, że możesz stracić tylko to, za co płacisz. Prawdą jest również, że nie ma ograniczeń co do tego, ile razy można stracić. I jak każdy loterysta wie dobrze, trochę pieniędzy wydanych w każdym tygodniu może zsumować po roku (lub życiu) nie trafienia w dziesiątkę. W przypadku kupujących opcje ból związany z powolnym niszczeniem twojego kapitału obrotowego powoduje, że odczuwasz to doświadczenie. Teraz, aby być uczciwym, sprzedający mogą doświadczyć wielu małych wygranych, a jednocześnie ukołysać się w fałszywym poczuciu sukcesu, tylko po to, by nagle odkryć, że ich zyski (i prawdopodobnie gorsze) zostały zatarte w jednym paskudnym ruchu przeciwko nim. Powracając do zaniku wartości czasu jako zmiennej ryzyka, mierzy się ją w postaci (niestałej) szybkości jego rozpadu, znanej jako Theta. Wartości te są zawsze ujemne dla długich opcji, ponieważ opcje zawsze tracą wartość czasu z każdym tikkiem zegara, aż do osiągnięcia czasu wygaśnięcia. Faktem jest, że wszystkie długie opcje, niezależnie od tego, co uderzy i jakie rynki, zawsze będą miały zerową wartość czasową po wygaśnięciu. Theta wytępi całą wartość czasu (znaną również jako wartość zewnętrzna), pozostawiając opcję bez wartości lub pewnego stopnia wartości wewnętrznej. Wartość wewnętrzna będzie reprezentować, w jakim stopniu wygasła opcja w pieniądzu. (Aby uzyskać więcej informacji, zobacz Ważność wartości czasu.) Rysunek 7: Opcje IBM Wartości Theta. Wartości przyjęte 29 grudnia 2007 r. Dla IBM na 110.09. Źródło: OptionVue 5 Oprogramowanie do analizy wariantów Jak widać na wykresie 7, wskaźnik spadku maleje w bardziej odległych miesiącach kontraktowych. Żółta uwydatnia połączenia, które są przy kasie i fioletowe, które stawia na pieniądze. Na przykład w styczniu 110 ma wartość Theta równą -7,58, co oznacza, że ​​ta opcja traci codziennie 7,58 wartości czasu. Ta stopa zaniku maleje dla każdego wezwania na miesiąc 110 z Tajemną -2,57. Jeśli myślimy o wartości czasu na tych 110 połączeniach, jak gdyby reprezentowało tylko jedną opcję z lipca, wyraźnie tempo utraty wartości czasu byłoby przyspieszające, ponieważ lipcowe połączenie jest coraz bliższe wygaśnięcia (tj. Tempo zaniku jest znacznie szybsze w przypadku opcji zbliża się do daty wygaśnięcia, niż gdy pozostało na nim dużo czasu). Niemniej jednak kwota premii za czas z tyłu miesięcy jest większa. W związku z tym, jeśli inwestor pragnie mniej czasu, ryzyko premii i wybrana opcja z powrotem miesiąc, kompromis jest taki, że więcej premii jest zagrożone ryzykiem Delta i Vega. Innymi słowy, możesz zwolnić tempo spadku, wybierając umowę na opcje z większą ilością czasu, ale zwiększasz ryzyko w zamian za wyższą cenę (pod warunkiem większej straty z powodu niewłaściwej ceny) i niekorzystna zmiana implikowanej zmienności (ponieważ wyższa premia wiąże się z wyższym ryzykiem Vega). W części VIII tego samouczka omówiono i przeanalizowano więcej informacji na temat interakcji Greków. Wspólne strategie opcji zawierają znaki Theta, które można łatwo kategoryzować, ponieważ strategia sprzedaży lub sprzedaży netto zawsze będzie miała pozytywną pozycję Theta, podczas gdy strategia kupna lub sprzedaży netto zawsze będzie miała negatywną pozycję Theta. jak widać na rysunku 8.BREAKING DOWN Theta Theta jest ósmą literą alfabetu greckiego. Jest częścią grupy środków znanych jako Grecy. inne środki obejmują deltę. gamma i vega. które są używane w wycenie opcji. Miara teta określa ryzyko, jakie czas nakłada na opcje, ponieważ opcje mogą być zrealizowane tylko przez pewien okres. Czas ma znaczenie dla handlowców opcji na poziomie koncepcyjnym bardziej niż praktyczny, więc theta nie jest często wykorzystywany przez przedsiębiorców przy określaniu wartości opcji. Różnice między Thetą a innymi Grekami Grecy mierzą wrażliwość cen opcji w odniesieniu do ich odpowiednich zmiennych. Delta opcji wskazuje na wrażliwość ceny opcji w odniesieniu do 1 zmiany w zabezpieczającym dokumencie bazowym. Gamma opcji wskazuje czułość delty opcji w stosunku do 1 zmiany w zabezpieczeniach podstawowych. Vega wskazuje, w jaki sposób cena opcji teoretycznie zmienia się dla każdego przesunięcia punktu procentowego w zmienności implikowanej. Theta dla kupujących opcje kontra autorzy opcji Jeśli wszystko inne pozostanie równe, zaniku czasu powoduje utratę jego wartości, gdy zbliża się data wygaśnięcia. Dlatego teta jest jednym z głównych Greków, o których kupujący opcje powinni się martwić, ponieważ czas działa przeciwko dłuższym posiadaczom opcji. Odwrotnie, rozpad czasu jest korzystny dla inwestora, który pisze opcje. Twórcy opcji korzystają z upływu czasu, ponieważ opcje, które zostały napisane, stają się mniej wartościowe w miarę zbliżania się czasu do wygaśnięcia. W związku z tym dla twórców opcji jest tańsze odkupienie opcji zamknięcia krótkiej pozycji. Przykład Theta Załóżmy na przykład, że inwestor kupuje opcję kupna o cenie wykonania wynoszącej 1150, gdy kurs podstawowy wynosi 1,125 za cenę 5. Opcja ma pięć dni do wygaśnięcia, a theta wynosi 1. Teoretycznie wartość z tej opcji spada 1 dziennie, aż osiągnie datę ważności. Dlatego opcja traci około 20 swojej wartości, jeśli wszystko pozostanie równe. Jest to niekorzystne dla posiadacza opcji. Załóżmy, że opcja pozostaje na poziomie 1125 i minęły dwa dni. Dlatego warto skorzystać z 3.CASsette IO Utilities Utilities, aby obsłużyć obrazy taśm i dyskietek ze starych komputerów kieszonkowych To darmowe oprogramowanie, na licencji GNU General Public Licence. Oprogramowanie jest dostarczane w niezmienionej postaci. Nie jestem niezawodny z powodu jakichkolwiek konsekwencji wynikających z jej użytkowania. Wszystkie znaki towarowe, nazwy firm lub produktów należą do ich właścicieli. Narzędzia tutaj były pierwotnie przeznaczone tylko dla komputerów kieszonkowych Casio. Niedawno zacząłem obsługiwać inne maszyny o porównywalnym formacie danych i dlatego zmieniłem nazwę pakietu z Casio Utilities na CASsette IO Utilities. Główny nacisk kładzie się nadal na urządzenia Casio, a większość dokumentacji obsługuje je właśnie. To jest w toku Nie wszystkie funkcje działają we wszystkich systemach operacyjnych i niektóre pliki mogą być źle obsługiwane. Przepraszam za jakiekolwiek niedogodności. Dodano opcję - d do listy850 w celu obsługi plików skopiowanych z dysku MD100. Przeróbka md100. Usunięto opcję - f i dodano opcję - p po informacji od Piotra Piatka. Naprawiono błąd powodujący niekończącą się pętlę podczas pisania plików wave w stylu Sharp. Wpływa głównie na wav2wav. Obsługa plików danych wymagała pewnych ulepszeń. Dodano opcję tłumienia wyjścia nagłówka do listy850. Dodano obsługę plików danych do bas850. Dodano wsparcie dla Unicode (UTF-8) do list850, listX07, bas850 i basX07. Opcja - i ignoruje dane z ramkami lub błędy parzystości na wejściu fali dla większości narzędzi list. Dodano pliki binarne dla hosta Windows CE (ARM, CE 3.0) Usunięto obsługę PPC dla OSX (nie mam już odpowiedniego kompilatora) list8000 teraz obsługuje wyświetlanie i eksport listy danych Range ViewWindow list8000 teraz eksportuje zmienną pamięć do pliku CAS (dla FA-121) . bas850 i md100 pozwalają na piping plików tekstowych. Naprawiono sekwencje specjalne (phi-gttheta). List8000 obsługuje teraz eksportowanie w formacie FA-123FA-124. list8000 - Dodano obsługę listingu kalkulatora graficznego fx-8000G z interfejsem FA-80. Udoskonalono wav2wav, aby obsługiwać więcej formatów. list74 - Uruchomienie startu TI-74. waveX07 - Dodano generator plików wave dla Canona X-07. basX07 - Dodano tokenizera dla Canona X-07. listX07 - Pierwszy program dla maszyny innej niż Casio: Canon X-07. Dostarczone jest następujące oprogramowanie: list702 - Pokazuje zawartość pliku binarnego lub WAV jako tekst lub dane BASIC. Ten program dotyczy FX-702P. Jest to adaptacja listy730. list730 - Pokaż zawartość pliku binarnego lub WAV jako tekst lub dane BASIC. Ten program dotyczy serii PB-100. Pierwotnie został stworzony przez Piotra Patyka. Dodałem różne formaty plików. list850 - Pokazuje zawartość pliku binarnego lub WAV jako tekst lub dane BASIC. Ten program jest przeznaczony dla wszystkich nowszych maszyn, począwszy od PB-700 włącznie z FX-850 i PB-1000. W zestawie znajduje się także FP-200. list8000 - Pokaż zawartość pliku binarnego lub WAV jako listę źródeł, rejestry, obraz ekranu lub tekst. Ten program jest przeznaczony do serii kalkulatorów graficznych z serii fx-8000G. List8000 może eksportować w formacie pliku zrozumiałym dla oprogramowania Casios FA-121 lub FA-124. listX07 - Pokazuje zawartość pliku binarnego lub WAV jako tekst BASIC. Ten program jest przeznaczony dla Canon X-07. list74 - Pokaż zawartość pliku binarnego lub WAV jako tekst BASIC. Ten program jest przeznaczony dla Texas Instruments TI-74. wave730 - Utwórz plik WAV z pliku binarnego. Ten program dotyczy serii PB-100. wave850 - Utwórz plik WAV z pliku binarnego. Ten program jest przeznaczony dla wszystkich nowszych maszyn, począwszy od PB-700 włącznie z FX-850 i PB-1000. The FP-200 jest również dołączony. Pliki mogą być tworzone w trybie (S) niskim lub (F) ast. waveX07 - Utwórz plik WAV z pliku binarnego. Ten program jest przeznaczony dla Canon X-07. bas702 - Utwórz plik WAV (lub kodowany binarnie lub ASCII) z podstawowego tekstu źródłowego. Ten program jest przeznaczony tylko dla FX-702P. bas730 - Utwórz plik WAV (lub kodowany binarnie lub ASCII) z podstawowego tekstu źródłowego. Ten program jest przeznaczony dla wszystkich starszych maszyn, zaczynając od PB-100 lub FX-700P i włączając FX-730P i FX-795P. bas850 - Utwórz plik WAV (lub kodowany binarnie lub ASCII) z podstawowego tekstu źródłowego. Ten program jest przeznaczony dla wszystkich nowszych maszyn, począwszy od PB-700 włącznie z FX-850 i PB-1000. W zestawie znajduje się także FP-200. Pliki WAV można tworzyć w trybie (S) niskim lub (F) ast. Możliwe formaty danych to tekst (do załadowania za pomocą ŁADUJ, A na niektórych maszynach) lub format wewnętrzny (do załadowania za pomocą ŁADUJ). basX07 - Utwórz plik WAV (lub plik binarny) z tekstu źródłowego BASIC. Ten program jest przeznaczony dla Canon X-07. wav2raw - wyodrębnia obraz binarny z pliku WAV. Działa dla wszystkich modeli. wav2wav - Odtworzyć bit pliku WAV na bit. Wynikowy plik można lepiej skompresować za pomocą bezstratnego oprogramowania kompresującego, takiego jak ZIP lub GZIP, niż w przypadku oryginalnego nagrania. Ponieważ odtwarzanie odbywa się nieco za szybko, program powinien działać dla dowolnego pliku WAV zarejestrowanego w standardzie Kansas City Standard z nośnikiem 2400 Hz. (Ive ostatnio zawiera wsparcie dla komputerów Sharp, które używają różnych częstotliwości.) Md100 - Obsługuje obrazy dyskietek MD-100 napisanych przez komputery PB-1000 lub PB-2000C. W niektórych systemach PC działa to nawet na prawdziwych dyskach w kieszeniach Generation of Casio. Komputery kieszonkowe Casio BASIC można pogrupować. W ramach każdej grupy można wymieniać pliki programów lub przekazywać programy bezpośrednio z jednego komputera na drugi za pośrednictwem ich interfejsów taśmowych. Nie wszystkie programy można wykonywać na wszystkich komputerach z tej samej serii, ponieważ niektóre słowa kluczowe są różne. Na przykład FX-700P nie rozumie REM. Więcej szczegółów na temat różnych wersji BASIC można znaleźć w moim arkuszu porównawczym BASIC. Seria PB-100 Jest to nazwa, którą Casio podarował swoim wczesnym komputerom kieszonkowym z BASIC. Grupa zawiera, zgodnie z późniejszym podręcznikiem Casio, następujące urządzenia: PB-100, PB-110, PB-220, PB-240, PB-300, PB-410, FX-700P, FX-720P, FX-730P , FX-770P, FX-785P, FX-790P i FX-795P. Posiadam niektóre z nich: PB-220, PB-300, FX-700P, FX-720P, FX-730P i FX-795P. Wszystkie modele mają kilka wspólnych cech: klawisz trybu przełącza pomiędzy trybem RUN lub WRT (program), wybiera tryby kątów i przekierowuje wydruki do opcjonalnej (lub wbudowanej) drukarki. Dostępnych jest 10 oddzielnych obszarów programu. Klawiatura ma pojedynczy klucz EXE. Funkcje przesunięte są wybierane za pomocą klawiszy prefiksu, które należy nacisnąć i zwolnić przed przesunięciem klawisza. Wewnętrzne kodowanie nie jest ASCII, ale coś bardzo specjalnego. Jeśli są Państwo zainteresowani szczegółami technicznymi, zobacz strony Piotra Piatek w Internecie. Wszystkie nagrania na taśmach zostały wykonane za pośrednictwem interfejsu FA-3, aczkolwiek PB-220 potrzebuje adaptera do mechanicznego połączenia. Prędkość transmisji wynosi 300 bitów na sekundę. FX-702P To urządzenie jest samo w sobie. Jego podstawowy dialekt jest trochę dziwny. Polecenia GOSUB. POWRÓT. PRINT i INPUT zostały zastąpione przez GSB. GNIĆ. PRT i INP. Wewnętrzny kod znaku jest czymś wyjątkowym. Nie jest to ani ASCII, ani kompatybilne z kodowaniem serii PB-100. Klawiatura ma klawisz trybu, który działa podobnie do urządzeń z serii PB-100. Dziesięć oddzielnych obszarów programu jest dostępnych. Klawiatura ma pojedynczy klucz EXE. Klawiatura alfa nie jest ułożona jak maszyna do pisania, lecz w kolejności alfabetycznej. Dwa klawisze Shift (F1, F2) są klawiszami prefiksu. Format taśmy ma pewne podobieństwo do formatu serii PB-100, ale wydaje się być wcześniejszym wariantem. Program do wyświetlenia pliku z taśmą jest zatem oddzielnym plikiem wykonywalnym, podczas gdy generator plików wave dla serii PB-100 (wave730) może tworzyć obrazy dla FX-702P. Wszystkie nagrania na taśmie zostały wykonane za pośrednictwem interfejsu FA-2. Prędkość transmisji wynosi 300 bitów na sekundę. PB-700, PB-770 i FX-750P Jest to nowsza generacja kieszeni BASIC, które nie posiadają klawisza trybu. Zamiast tego klawisz ENTER na klawiaturze numerycznej służy do obliczeń w trybie bezpośrednim, natomiast klawisz powrotu służy do wprowadzania poleceń i wierszy programu BASIC. Klawisz Shift musi być wciśnięty i przytrzymany razem z kluczem, tak jak na maszynie do pisania. Dostępnych jest dziesięć oddzielnych obszarów programu. Słowo kluczowe (PROG) przełącza między obszarami bez uruchamiania programu. Występuje subtelna różnica w obsłudze funkcji logarytmicznych. Systemy PB (seria PB-700 i PB-1000, patrz poniżej) używają LGT dla logarytmu podstawowego 10 i LOG dla logarytmu naturalnego. Wszystkie inne maszyny, w tym stara seria PB-100, używają odpowiednio LOG i LN. Wewnętrzne kodowanie to ASCII ze znakami graficznymi w rozszerzonym zestawie. Jeśli są Państwo zainteresowani szczegółami technicznymi, zobacz strony Piotra Piatek w Internecie. FX-750P ma irytujące dziwactwo: nie rozumie małych liter, ale nie wyświetla nic. Dzięki temu niemożliwe jest edytowanie linii z małymi literami przesyłanymi z PB-700 lub ładowanych z pliku PB-700. Posiadam PB-700 i PB-770 z interfejsem FA-10 i FX-750P z FA-20. Testowałem swoje programy na tych maszynach i interfejsach. Prędkość transmisji wynosi 300 bitów na sekundę. Modele FX-850P, FX-870P, FX-880P, FX-890P, VX-1 do 4, Z-1 i PB-1000 Te urządzenia mają nową implementację BASIC, o nazwie JIS Standard BASIC firmy Casio. PB-1000 ma system plików RAM, podczas gdy systemy FX i VX zachowują dziesięć obszarów programu we wcześniejszych maszynach. Wewnętrzne kodowanie to ASCII, ale podstawowe słowa kluczowe i numery linii są kodowane inaczej (numery linii mogą teraz osiągnąć maksymalnie 65535, nie tylko 9999). Rozszerzone zestawy znaków różnią się między PB-1000 a innymi maszynami tej serii. PB-1000 dzieli zestaw znaków PB-700 ze specjalną grafiką, podczas gdy systemy FX, VX i Z wyświetlają symbole matematyczne i naukowe. Z-1 i jego rodzeństwo FX-890P nie mają interfejsu taśmy. Wszystkie maszyny oprócz PB-1000 łączą się z interfejsem FA-6. Interfejs ten oferuje wyższą prędkość transmisji 1200 bitów na sekundę. Format bloku danych jest wariantem schematu PB-700, ale kodowanie programów BASIC jest inne. Możliwe jest załadowanie pliku zapisanego przy pomocy SAVE, A na PB-700 do FX-850P, i odwrotnie jest to możliwe. Musisz ograniczyć prędkość do 300 bitów na sekundę (SAVE (S) i LOAD (S) na FX-850P.) Mogłem tylko częściowo przetestować interfejs taśmy z VX-1 lub FX-870P, ponieważ mogłem tylko pisać ale nie odczytuje programów lub danych przez interfejs FA-6 z tymi maszynami. Systemy FX-850PFX-880P mogą odczytywać taśmy z serii PB-100 za pomocą specjalnych poleceń (PBLOAD. PBGET). PB-1000 ma podobne złącze, ale różnice mechaniczne i elektryczne uniemożliwiają korzystanie z FA-6. PB-1000 wykorzystuje interfejs FA-7, który oferuje jeszcze większe prędkości przesyłu (do 2400 bitów na sekundę, wybierany przełącznikiem DIP na interfejsie). Z-1 i FX-890P nie obsługują już taśm, ale nadal mogą być używane z translatorem tekstu źródłowego bas850 i interfejsem szeregowym lub USB. FP-200 To maszyna klasy A4 w swojej klasie. BASIC jest podobny do PB-1000, ale zawiera również funkcje Microsoft-BASIC. Dołączona aplikacja arkusza kalkulacyjnego CETL jest unikalna. Format taśmy jest podobny do maszyn podobnych do FX-850P, aby objąć obsługę w tych samych programach. W większości przypadków przełącznik -2 poradzi sobie z różnicami. Niektóre pliki zakodowane w ASCII są kompatybilne między rodzinami, w szczególności: Prędkość taśmy wynosi 300 bodów (tylko w przypadku wolnego formatu). Wewnętrzne kodowanie jest inne, plików binarnych nie można wymieniać. Format ASCII FP-200 jest rozumiany przez FX-850P, ale nie przez PB-1000. Nie mogłem tego przetestować za pomocą VX-4 lub FX-870P (patrz wyżej). FP-200 rozumie format ASCII wszystkich innych maszyn, z uwzględnieniem prawidłowej prędkości. Pliki można przekazywać za pomocą list850 i bas850, aby tworzyć pliki dla różnych platform. Napęd dyskietek MD-100 z kalkulatorami PB-1000 i PB-2000C MD-100 nie ma interfejsu taśmowego, ale kogo to obchodzi, kiedy dyskietka z prawdziwym systemem plików jest łatwo dostępna Mam dwa kalkulatory kieszonkowe, które łączą się z MD-100 : komputer PB-1000 BASIC i PB-2000C, które można zaprogramować w wariancie C (interpretowanym, dość powolnym). Program md100 rozumie format dysku. Dostępny jest BASIC ROM OM-53B dla PB-2000C, który zamienia go zasadniczo w PB-1000 z inną obudową, ale jeszcze tego nie widziałem. Piotr Piatek ma emulatory dla wszystkich. Inne urządzenia Casio fx-8000G To nie jest PODSTAWOWY komputer kieszonkowy, ale kalkulator graficzny. Dzięki interfejsowi FA-80 można zapisywać programy, rejestry, pliki graficzne i tekstowe na taśmie kasetowej. list8000 obsługuje listę tych plików. Sam nie mam interfejsu, więc rozwój jest powolny. Pliki mogą zawierać więcej niż jeden typ danych. Program wyświetla zawartość, jaka pojawia się w pliku. Grafika jest konwertowana na pliki BMP na żądanie. Nagrywanie odbywa się z szybkością 2400 bodów. Być może będziesz musiał ustawić swoje oprogramowanie audio na odpowiednią częstotliwość próbkowania dla niezawodnego odczytu plików WAV. Canon X-07 Canon X-07 to niewielka maszyna z potężnym interfejsem BASIC i wbudowanym interfejsem kasety. Właśnie zacząłem go wspierać z listą programówX07. waveX07 i basX07. Encje są w trybie szybkim z szybkością 1200 bodów, format obsługiwany już przez bibliotekę fal w tym projekcie. Kodowanie na niskim poziomie jest nieco inne: 8 bitów, bez parzystości, co najmniej 2 bitów stopu. Musiałem dostosować wygenerowany wzór fal, aby CLOAD działał niezawodnie. Texas Instruments TI-74 TI-74 jest następcą komputera CC-40 BASIC, który nie udał się komercyjnie, ponieważ początkowo nie było dostępne żadne urządzenie pamięci masowej. Nowszy TI-74 może być wyposażony w interfejs kasety CI-7 poprzez złącze DockBus. Logika interfejsu jest wbudowana w komputer, a nie w interfejs. Dzięki temu nie można używać CI-7 przez adapter z CC-40. CC-40, z którego istnieje tylko kilka prototypów, ma wbudowany interfejs kasety i może współpracować z moimi narzędziami, ale nie mogę tego przetestować samodzielnie. BASIC jest jednym z najlepszych, jakie można znaleźć dla dowolnego komputera kieszonkowego w swojej epoce. Obsługuje wyrafinowane IO, podprogramy z parametrami, długie nazwy zmiennych i wiele innych. Interfejs kasety naśladuje urządzenie DockBus (lub HexBus) 1. Może nagrywać programy BASIC za pomocą SAVE1.NAME, które są ładowane przez OLD1.NAME lub tylko OLD1. Interfejs obsługuje pliki danych sekwencyjnego trybu tekstowego dla programowego wejścia i wyjścia, jak również . Możesz nawet LIST1.NAME program w ASCII, ale nie można go załadować z powrotem do komputera. Pracuję nad rozwiązaniem, ale może to zająć trochę czasu. Format pliku falowego jest raczej specjalnym wariantem Kansas City Standard (KCS) używanym gdzie indziej: częstotliwości to 1400 Hz i 700 Hz, a prędkość to 1400 bitów na sekundę. Oznacza to, że tylko połowa fali jest używana dla bitu zerowego 700 Hz Synchronizacja jest całkowicie różna od KCS, a bajty są kodowane bez bitów start, parzystości lub stopu. Informacje są przesyłane w blokach do 64 bajtów danych netto. Rekordy logiczne mogą składać się z wielu bloków. Każdy blok jest chroniony przez prostą sumę kontrolną i jest przesyłany dwukrotnie dla nadmiarowości. Zapisywanie programu BASIC jest stosunkowo szybkie, ponieważ jest przesyłane jako jeden duży rekord logiczny. Istnieje wystarczająco dużo czasu na synchronizację, aby utworzyć plik fal 30-sekundowych dla krótkiego programu, ale dłuższy program nie spowoduje, że plik będzie zbyt długi. Pisanie pliku ASCII to zupełnie inna sprawa: dodatkowe obciążenie jest dodawane dla każdego rekordu pliku. Właściciele interfejsu PC mają więcej opcji: mogą bezpośrednio zapisywać i ładować z systemu plików komputera. Pliki programów są binarne i zazwyczaj mają rozszerzenie PGM. Program DOS TIC74 dostarczany wraz z oprogramowaniem interfejsu tworzy taki plik z podstawowego pliku tekstowego. Zawartość tego pliku jest taka sama, jak pojedynczy duży rekord przesyłany przez interfejs kasety. Zamierzam zabrać taki plik PGM jako dane wejściowe i utworzyć plik wave do załadowania go bez interfejsu komputera. Bądź cierpliwy list74 jest już w stanie wyświetlić taki plik jako listę BASIC lub wyodrębnić go z nagrania. Jak obchodzić się z nagraniami taśmowymi Podłącz interfejs taśmy za pomocą kabla mikrofonu bezpośrednio do karty dźwiękowej. Uruchom wybrane oprogramowanie dyktafonu z następującymi parametrami: format pliku WAV. 8 bitów na próbkę. Więcej bitów jest możliwych, ale nie jest potrzebne. Nie używaj zmiennoprzecinkowego formatu 11025 lub 22050 próbek na sekundę (To dobry pomysł, ale nie jest obowiązkowe, aby nagrywać 2400 bitów na 44100 próbek na sekundę.) Monofoniczny. Poziom nagrywania wystarczająco wysoki, aby wypełnić zakres dynamiki pliku wave. Alternatywnie użyj edytora dźwięku, takiego jak Audacity, aby wzmocnić sygnał. Wyślij program lub dane z komputera kieszonkowego za pomocą przycisku ZAPISZ. ZAPISZ WSZYSTKO. PUT lub WRITE i rozpocznij nagrywanie. Zatrzymaj nagrywanie, gdy zwróci się komunikat Gotowa. Nagrania o wysokiej prędkości (1200 bodów lub więcej) utrudniają użytecznym interferencjom fal, ponieważ redundancja jest znacznie mniejsza. Jeśli masz problemy, spróbuj ustawić zmienną środowiskową WAVEPHASE 1 lub odwróć nagranie za pomocą edytora dźwięku i spróbuj ponownie. Występuje problem z moim komputerem iMac i jego wewnętrzną kartą dźwiękową. Poziom zapisu na wejściu liniowym jest bardzo niski. Ive podłączyłem Soundblaster USB z wejściem mikrofonowym. Znacznie tańsza wtyczka dźwiękowa noname USB z wejściem mikrofonowym również sprawdziła się dobrze. Odtwarzanie za pośrednictwem wewnętrznej karty dźwiękowej jest w porządku. Podłącz wejście EAR interfejsu taśmy do wyjścia PHONES karty dźwiękowej. Jest problem do rozwiązania: Potrzebny będzie adapter do podłączenia wyjścia stereo karty dźwiękowej (tylko jeden kanał) do wejścia mono interfejsu taśmowego. Możesz uszkodzić kartę dźwiękową za pomocą kabla dostarczonego przez interfejs taśmowy, ponieważ przed kontynuowaniem wykonuje krótkie zwierania jednego z kanałów wyjściowych Przeczytaj poprzedni akapit Jeśli wszystko jest poprawnie podłączone, wprowadź odpowiednie polecenie LOAD (ALL), READ lub GET, a następnie zacznij odtwarzać plik WAV. Ustaw poziom wyjściowy wyżej niż normalnie. Jeśli jest zbyt głośno dla twoich uszu, jest odpowiedni dla twojego małego komputera Jeśli komputer kieszonkowy odczytuje i przetwarza dane w programie, korzystając z wtyczki REMOTE interfejsu taśmy, aby zatrzymać odtwarzanie w trakcie pracy, będziesz musiał naśladować przez zatrzymanie i wznowienie odtwarzania ręcznie. Pliki programów nie stanowią problemu w tym zakresie. Odświeżanie Oryginalne nagrania (lub nagrania z innych źródeł w Internecie) mogą nie być optymalne do archiwizacji. Bezstratne programy kompresji, takie jak ZIP lub GZIP, nie lubią sygnałów analogowych Niektóre nagrania znalezione w innych miejscach nie informują o prawidłowym interfejsie taśmy po zakończeniu nagrywania. Może to nawet doprowadzić do braku linii programu podczas pobierania do kalkulatora kieszonkowego. wav2wav tworzy bitową kopię pliku WAV zarejestrowanego w Kansas City Standard lub w jednym z obsługiwanych wariantów. Wszystkie modele Casio używają tego schematu nagrywania, nawet w trybie szybkim lub szybkim (1200 lub 2400 bitów na sekundę), gdzie bit jest reprezentowany przez jedną lub dwie fale zamiast czterech do ośmiu w trybie standardowym z szybkością 300 bitów na sekundę. Oprogramowanie może przekodować nagranie z dowolną prędkością 300, 1200 lub 2400 bitów na sekundę w dowolnej z tych prędkości. Istnieją dwa specjalne tryby dla innych urządzeń: 500 bitów na sekundę dla komputerów kieszonkowych Sharp i 1400 bitów na sekundę dla TI-74 lub TI-95. Są one zawsze używane do wprowadzania i wyprowadzania. Zmiana prędkości dla tych nagrań nie ma sensu, ponieważ powstałe pliki będą bezużyteczne. Wzorzec wyjściowy jest falą sinusoidalną dla wszystkich prędkości z wyjątkiem TI, w którym stosowana jest fala prostokątna. Może się to zmienić w przyszłości. Program nazywa się w następujący sposób: Jeśli chcesz przekodować plik o szybkości 300 bodów (na przykład plik z PB-700) do pliku o dużej szybkości dla PB-1000, użyj opcji - oh sam. Domyślnie prędkość wejściowa wynosi 300. Jeśli chcesz przekodować plik wysokiej prędkości z PB-1000 do załadowania do FX-850P, użyj obu opcji - ih i - of. Opcje są analizowane od lewej do prawej. Więc nawet kombinacja - t-works, ale jest bezużyteczna. Możesz użyć opcji - f na plikach o szybkości 300 bodów. Jest to możliwe, ponieważ częstotliwości są takie same. Zgłoszona liczba bitów będzie błędna czterokrotnie, a niezawodność konwersji zostanie znacznie zmniejszona. Jeśli przekonwertowany plik nie może zostać odczytany przez urządzenie, spróbuj ponownie przy użyciu zmiennej środowiskowej WAVEPHASE1. Jeśli plik jest nagrywany z bardzo małą głośnością, spróbuj ustawić zmienną środowiskową WAVETHRESHOLD na wartości powyżej 10. W każdym razie lepiej załadować plik do edytora audio i tam go normalizować. Konwersja do innych formatów Nagrania można łatwo analizować (i archiwizować), konwertując je do formatu binarnego. Dostępnych jest kilka formatów: Bajtowy format binarny to po prostu dane dekodowane. Traci on tak zwane sekwencje wiodące używane do synchronizacji dekodera i oddzielnych bloków danych. Bajty z ramkami lub błędy parzystości są pomijane. Format jest najłatwiejszy do zrozumienia dla ludzi i stanowi podstawę programów aukcji. Format binarny programu Word jest odmianą formatu binarnego, który zachowuje więcej informacji o oryginalnym strumieniu danych. Sekwencje wejściowe są kodowane jako wartość specjalna, wszystkie informacje o ramkach i parzystości są zachowywane w górnym bajcie każdego słowa danych. Word raw format to tylko 12 bitów na bajt danych (z bitem startowym, stop i parzystości) rozszerzonych na 16-bitowe słowa. Dane surowe kodowane ASCII to format generowany i akceptowany przez interfejs szeregowy Piotrsa. wav2raw konwertuje plik WAV na jeden z wymienionych wyżej formatów: Dołączanie - na końcu opcji - s. - f lub - h ma taki sam efekt jak ustawienie zmiennej środowiskowej WAVEPHASE na 1. Może to pomóc w uniknięciu błędów odczytu z powodu złej fazy pliku falowego. Użyj opcji - f - pN2, aby przeczytać format Canon X-07. Kalkulatory graficzne Casio fx-8000G i fx-8500G z interfejsem FA-80 używają formatu - h. Moje testy dały najlepsze wyniki z opcją - h-. Wyświetlanie jako tekst Te programy interpretują plik WAV lub plik binarny i wyprowadzają jego zawartość jako program lub listę danych. Programy są list702. list730 i list850. Wszystkie programy zapisują swoje wyniki na konsoli, którą można przekierować do pliku. Lista komputerów Casio BASIC 70 obsługuje tylko FX-702P. Pliki danych nie są obsługiwane. List730 obsługuje serię PB-100, czyli FX-730P. Pliki danych nie są obsługiwane. Użyj opcji - e. jeśli chcesz przetłumaczyć wyjście później z bas730 list850 wie o wszystkich innych kalkulatorach Casio BASIC, zaczynając od PB-700, czyli FX-850P. Obsługiwane są również pliki danych i pliki ASCII zapisane przy pomocy SAVE, A. Użyj opcji - eP (lub - uP) i - lP podczas wymieniania programu PB-1000. -2 obsługuje wszystkie specyfikacje FP-200, szczególnie różne kodowanie binarne. Kalkulatory graficzne Casio list8000 wyświetla i konwertuje pliki z kalkulatora graficznego fx-8000G. Wszystkie typy rekordów są obsługiwane. Polecenie ZAPISZ Nazwa A zapisuje mieszaninę wszystkich dostępnych formatów: programów, zmiennych (pamięci), grafiki i plików. list8000 obsługuje sekwencje specjalne w łańcuchach takich jak inne programy i odziedziczył opcje strony kodowej listX07. Sekwencje specjalne są zgodne z formatem pliku CAT (patrz poniżej). Grafika jest konwertowana na pliki BMP, jeśli dostępna jest opcja - g. Po nim musi znajdować się nazwa pliku kończąca się na. bmp i powinna zawierać znak, który jest zastąpiony przez 1 do 3. Pierwszy plik ma dokładną rozdzielczość wyświetlania równą 96 na 64 piksele. Drugi plik ma rozdzielczość 192 na 128 pikseli. Jest on wykorzystywany wewnętrznie przez kalkulator do drukowania w wysokiej rozdzielczości. Jeśli przełącznik wyboru po lewej stronie jest ustawiony na N zamiast HD podczas rysowania wykresu, tylko co druga kropka zostanie narysowana w obrazie o wysokiej rozdzielczości. Oba formaty są częścią zapisu grafiki na taśmie. Tworzy się trzecie zdjęcie, które jest kopią pierwszego, ale trzy razy większego rozmiaru: Każdy piksel jest rysowany jako kwadrat 2x2 z pustą kolumną po prawej stronie i pustym rzędem na dole. To wygląda bardziej jak prawdziwy ekran, w którym pojedyncze kropki są nieco oddalone. list8000 obsługuje konwersję do formatów plików zrozumiałych dla oprogramowania FA-121 124 od Casio (patrz poniżej): format CAS dla FA-121 i format CAT dla FA-122 i późniejszych. Z odpowiednim kablem szeregowym od Casio lub Yellow Computing - ich kabel interfejsu FX łączy się ze zwykłym portem szeregowym - możesz podłączyć wszystkie najnowsze kalkulatory graficzne za pomocą okrągłego złącza z trzema pinami. Wbudowanego portu USB niektórych kalkulatorów nie można używać bezpośrednio, ponieważ FA-124 nie obsługuje go w tradycyjnym trybie (FA-123), który jest wymagany w formacie CAT. Jest kilka rzeczy do rozważenia: plik CAS: użyj opcji - cas i dostarcz plik wyjściowy kończący się na. CAS. Opcjonalnie opcjonalnie może pojawić się wskaźnik, który należy umieścić w pliku: Wszystkie elementy, programy, pliki edytorów, pamięć lub informacje o zakresie. Format pliku CAS jest używany przez FA-121, stary 16-bitowy program Windows. Powinieneś ograniczyć się do 83 nazw plików dla pliku wyjściowego. Pliki CAS można również importować za pomocą nowszego oprogramowania FA. Nie ma konwersji kodu. Nawet najlepszy kalkulator liniowy tej generacji, CFX-9800G, powinien z powodzeniem wykonać cały stary kod Fx-8000G. Po otwarciu pliku typu A w FA-121, brakujące elementy, takie jak współczynnik, są tworzone automatycznie, ale zawierają tylko domyślne informacje. Użyj opcji - casP lub - cas7, jeśli kierujesz na plik fx-7700GB, który obsługuje tylko transfery programów. Ta ostatnia opcja powoduje umieszczenie zmiennej pamięci i dowolnych plików edytora w obszarach programu A. B. itd. Pierwszy z nich, Prog A. zawiera program do ustawiania zmiennych A Z na wartości znalezione w pliku źródłowym. Oryginalne nazwy plików edytora są zapisywane jako komentarze na początku każdego wygenerowanego programu. Nie próbujemy tłumaczyć żadnych wywołań nazw programów. CAT file: Use option - cat and provide an output file ending in. cat. This file is accepted by FA-122124. FA-124 must be in the traditional mode (Model Type: fx-7400G CFX-9850G) even if you connect a newer calculator. An optional prefix for the program file name conversion must follow the option directly (see below). If you dont have a three pin cable you can still try the conversion option of FA-124 and transfer the converted file in native FA-124 mode over USB. list8000 converts programs, editor files, variables AZ and Range information into both formats. Graphics go into the CAT file format only. All information is written to a single file. In a CAT file, programs are renamed according to their position in the source recording. If you SAVE to cassette with a filename, this will be used as a prefix. You can optionally provide your own prefix after the option - cat. A in the prefix will become the program area digit. If no is present in the prefix, program 0 will get the prefix name alone while the digits 1 9 are appended to the following program areas. Calls to Prog n are automatically converted to Prog name . The tape recording lacks information about the original program areas of the saved programs. This can cause trouble if you are calling one program from the other. Option - p allows to set the area for the first program in the file to a value other than 0 . There are some more syntax differences between the various generations of Casios programming language. Notably the instructions Scl. Cl and Dt cannot be converted into the CAT format. To overcome this, some commands are replaced when a CAT file is created. This should avoid syntax errors but cannot help in all cases. E. g. array access is replaced by list access, but if you rely on a specific mapping between variables AZ and the arrays, you have to modify the program. The Mcl command is changed to clear variables A Z and setup List 1 with 26 elements. Add it in the beginning of your arrray handling program. You should adjust the list size manually after the conversion. Text files are stored in the tape recording under their name together with their passwords. The CAT file format keeps both the name and the password but since this file format is ASCII you can simply edit passwords out. Dont edit the file contents directly in the cat file because the length field will no longer be correct CAS files do not contain passwords. Graphics in a CAT file are converted to various formats: Picture1 to Picture3 contain a centered image (96x64 on a 128x64 screen) in three colors: orange. blue and green. Picture4 has the original 96x64 resolution in blue. Calculators with a wider screen will reject it (in fact, I have yet to find a calculator that loads it.) The high resolution image is not converted because no other calculator can deal with it. In the first example, the first program on the tape will be renamed MYAPP-3.FX. The redirection operator gt is optional for CAT file creation and must be omitted for CAS file output. Canon X-07 listX07 handles the Canon X-07. It supports binary and WAV files from CSAVE only. The escape sequences are a bit different from the Casio machines because the charset differs considerably. See here for a complete list. You can use the DOS or Windows extend character set (code pages 437 or 1252 respectively) on the output with option - c. This will make many special characters in strings or comments, entered with the GRPH key on the X-07, readable on your system. If you want to translate the output later with basX07 you should use option - e and you may use option - c. Both can be mixed. If a matching extended character in the selected code page is found, it will be output instead of the escape sequence. list74 handles the TI-74. It supports binary files or WAV files. A binary file can either be created by wav2raw. be extracted by option - r in an earlier run of list74. or come from the TI PC interface: saved from a TI-74 (or CC-40) or created by the TIC74 compiler. Use option - r if you want to create a file that can be sent to the TI-74 by the PC interface software. The filename must follow the option char directly. No listing is produced then. list74 works for sequential files written to device 1. as well. Options - e and - c work similar to listX07 but the TI supports less national characters. At least some special characters like auml, ouml, uuml or szlig can be used. They cannot be entered directly on the device but may slip in through the PC interface or appear in data files. Creating from binary files Three programs interprete a binary file and create a WAV file from it that can be transferred to the calculator via the sound card. The programs are wave730 . wave850 and waveX07 . The first program handles the Casio PB-100 series, namely the FX-730P and, as a side effect, the FX-702P (but the program name stored in the file isnt correctly displayed on screen.) The second is written for the other BASIC calculators beginning with the PB-700, namely the FX-850P. waveX07 handles the Canon X-07. The lead-in sequences are shorter than in an original file coming from the tape interface. This saves some time when loading the files. The FP-200 needs slightly longer lead-ins: use the -2 switch Creating from BASIC source files These programs take a source file, which might have been created by one of the list utilities or just typed in on the PC, and create a tape file in one of the following formats from it: WAV file, binary file or ASCII encoded file for Piotrs serial interface. The programs are bas702 . bas730, bas850 and basX07 . The last two can create plain ASCII source files for transmission through a serial interface. BASIC programs can be written with lowercase or mixed case keywords. The utilities translate everything outside strings, comments or DATA lines to uppercase before further processing. Uppercasing can be suppressed for the newest machines which support case sensitive variable names. You can use a single apostrophe () instead of REM to start a comment. This is natively supported on the FX-850P and later models and on the X-07 but not on the older machines where it will be translated to REM or :REM depending on its position. Lines that do not start with a line number are ignored. This way you can have lenghty comments in your source code which are not downloaded to your pocket computer. Different generations and lines of pocket computers use different BASIC dialects. The differences are sometimes huge and sometimes very subtle. This ranges from the almost exotic FX-702P BASIC variant with abbreviated keywords like PRT instead of PRINT to minor quirks like the lack of USING in the FX-850P or the renaming of the logarithm functions in the PB-700 and PB-1000. The translators know about some of these specifics and try to bridge the gaps with special options. Of course some restrictions like variable name syntax or memory organization or the lack of functionality cannot be overcome. But I tried hard to avoid these nasty SN Error or ERR-2 messages resulting from unknown keywords where a perfect replacement on the target machine exists. VAC vs. CLEAR is a good example for this. Within the same family, some commands are valid for one machine but not for the other. The statistics functions of the FX-750P are unavailable on the PB-700. bas850 translates these functions to tokens but the PB-700 cannot list or execute them. This is equally true, if you load a programm written on and saved by the FX-750P directly into a PB-700. You will find a detailed analysis of the various BASIC dialects in my BASIC Comparison Sheet . You can translate source files especially written for the FX-702P or from newer Casios standard BASIC keywords like PRINT or INPUT are automatically translated to the special syntax of the FX-702P. The prefix FACT function is replaced by the FX-702P postfix factorial . Some unkown commands like REM or DATA are completely removed. This can lead to lines being deleted and therefore unavailable as jump targets. The PB-700PB-1000 logarithm syntax is supported with the - l option. The FX-702P supports only one array named A(). On the PB-100 series you better use Z() after DEFM when you do not want to overlap your standard variables with your array. bas702 translates the arrayname Z() to array A() to emulate this behaviour. bas702 supports escape sequences anywhere in the code in order to allow the use of the special characters of the pocket computer. An escape starts with a backslash character followed by either one or two characters (see table below) or a two digit hexadecimal code. Set the - e switch on list702 to include these sequences in a program listing Here is the character map: Code 0F is used as the space character. The BASIC tokens range from 60 to AF. The character escape sequences are: DG (deg), gt (greater or equal), lt (less or equal), ltgt (not equal), PI and E (exponent). These are case insensitive: PI and pi are equivalent. The strings gt. lt. ltgt. PI and E in numbers are automatically translated when they occur in normal code. There is no need to escape them, except when you want to use them in strings. The character is treated as deg. is the up arrow and is PI. and are lt, gt and ltgt respectively. So in order to print the character pi, any of the following will do: PI. pi. Pi or 3B. Outside of strings, PI. pi or Pi are also valid. FX-730P family If you have a source file from an FX-702P, which uses some special keywords like PRT or INP. translate your source with the - o option. If you want to port a program from one of the newer machines like the FX-850P, try option - n. The program does its best to translate to the older or newer syntax, but it is not foolproof. The FX-702P postfix factorial is translated to the prefix FACT function. The PB-700PB-1000 logarithm syntax is supported with the - l option. Since the BASIC of the PB-100, PB-300, FX-701P and FX-801P lacks some keywords, notably REM. use option -1 if you want to target one of these. The unknown commands are then excluded from the output. This may lead to lines being dropped as a whole. Their line numbers are no longer available as jump targets Options - n and - o are mutually exclusive. Option -1 may be combined with either one. bas730 supports escape sequences anywhere in the code in order to allow the use of the special characters of the pocket computer. An escape starts with a backslash character followed by either one or two characters (see table below) or a two digit hexadecimal code. Set the - e switch on list730 to include these sequences in a program listing Here is the character map (courtesy Piotr Piatek): Code 00 is used as the space character. The BASIC tokens range from 80 to D1. The character escape sequences are: gt (greater or equal), lt (less or equal), ltgt (not equal), PI. E-. E (exponent), SD. SL (small caps), GA (gamma), SI (lowercase sigma), -1 (small), . (quotes) (circle), SM (Sum), DG (deg), (triangle), (multiply), : (divide), SP (spade), HT (heart), DI (diamond), CL (club), MU (micro), OM (omega), YN (Yen), SQ (square), . (dot) and (block), (backslash), (gray block), (thick slash), Bgt (B) and TA (tau). These are case insensitive: PI and pi are equivalent. The strings gt. lt. ltgt. PI. E - and E in numbers are automatically translated when they occur in normal code. There is no need to escape them, except when you want to use them in strings or comments. The character is treated as deg. . and are the left, right, up and down arrows. So in order to print the character pi, any of the following will do: PI. pi. Pi or 1B. Outside of strings, PI. pi or Pi are also valid. PB-700 and FX-850P families and the FP-200 - tT format is just plain text with all source text translations performed. You can send the result directly to the serial or USB interface. The outfile can be omitted, the output goes to standard out then. This way, you can send the output directly to other utilities like md100. In Windows, the following commands will setup the serial port and send the file directly to the pocket computer: The mode command is necessary only once. On an FX-850P use LOADCOM0:6. to load the file. Ive tried this successfully with the USB-interface by Manfred Becker (see below .) - tA format is compatible with the PB-700, FX-850P series machines and the FP-200. But its slow because each program line is preceeded by a lead-in sequence of about two seconds. This is necessary because the computer needs some time to compile one line in memory before the next line arrives. This is still better than typing the code in. The FP-200 and the FX-850P support - tB format, a blocked variant of the - tA format. Blocking creates less but larger blocks and is therefore faster to load but cannot be used for the PB-1000. The -2 switch sets all relevant options for the FP-200 and adds some special quirks. If you target to this machine, use the -2 switch - t2 creates a binary file for the FP-200. It sets the -2 switch as well. To get a program from the PC into your PB-700, PB-770 or FX-750P, use switch - t7 to create a binary file. This will be much faster than - tA . - t8 is preferable over - tA or - tB if you target the FX-850 or the PB-1000. For the latter, - lF is needed as well, if you are using the correct LGTLOG syntax of the PB series. The token table only contains the FX syntax LOGLN keywords. The - lF switch takes care of the source text translation before the tokenization takes place. There is another caveat: The token table contains all keywords for all known variants of JIS BASIC. If your program uses such a keyword as a variable name on a machine where it is not a reserved word (e. g. VAC which is a replament for CLEAR on the FX-850P but free for use on the PB-1000) the tokenizer will accidently translate your variable name to a token. Rename your variable or use - tA mode instead In any case, be careful to select a speed ( - w or - f ) that is supported by your pocket computer Use - u if you plan to load the file into your FX-750P: This machine does not support lowercase letters On the other hand, option - l allows lowercase variable names and keywords as accepted by the newer machines otherwise, everything outside strings and remarks is translated to uppercase. If you have a source file from an FX-702P or from the PB-100FX-730P series, which have some special keywords like VAC, the - o option might help. The program does its best to translate to the new syntax, but it is not foolproof. The FX-702P postfix factorial is translated to the prefix FACT function. There is a problem with the different meanings of LOG, LN and LGT in the various versions of Casio BASIC. The PB-700 series, the PB-1000 and the FP-200 use LGT for the base 10 logarithm and LOG for the natural logarithm. The other machines use LOG for base 10 logarithm and LN for the natural logarithm. If your source file specifies LOG and LN but you want to transmit the file to a PB-700 or PB-1000, specify - lP to force a translation. In the opposite case, specify - lF if you transfer, for example, a source from a PB-700 to a FX-850P. If your source file already contains the correct logarithm functions, do not specify a conversion There is an Exception: If you are creating a binary file for the PB-1000, you need to use - lF (see above.) With option - d data files can be created for all machines. As a modern PC does not allow the pausing of the sound output to the tape interface by means of a Remote plug, there is the ltdelaygt parameter. It controls the time in tens of seconds between data lines or blocks. You may have to increase this value from its default (two seconds in non blocked mode, four seconds in blocked mode) if you program misses data. There are differences between the PB-700 and later systems. A PB-700 PUT command creates an unnamed tape file with as many lines as there are items in the command. Later systems use OPEN and CLOSE to create named files with as many lines as there are PRINT statements. The FP-200 and the FX-850P support large blocks of several records before a new lead-in sequence is output. Option -2 forces this mode. For other systems just set the the ltcountgt parameter of option - d to B. Here are a few examples: PB-700: bas850 - w - d30,1 DATAFILE. DAT DATAFILE. WAV This matches a single variable as in GET A. Set option - d30,3 for GET A, B,C. The value 30 for the lead-in time is arbitrary. In most cases the default of 20 works fine. For each tape file, two blocks are written to the wav-file, header and data, each with its own lead-in of the requested length FX-850P: bas850 - w - d, B DATAFILE. DAT DATAFILE. WAV This will create a file with large data blocks. The lead-in time per block is 40 in this case. You can try to decrease it to 30 or some such. FP-200: bas850 - w - d -2 DATAFILE. DAT DATAFILE. WAV Option -2 forces large blocks and a modified line end (CR LF). This is FP-200 specific. bas850 supports escape sequences anywhere in the code in order to allow the use of the special characters of the pocket computer without resorting to the CHR function. An escape starts with a backslash character followed by either one or two characters (see table below) or a two digit hexadecimal code. Set the - e switch on list850 to include these sequences in a program listing Here are the character maps for the PB-700 and the FX-850P (courtesy Casio and some editing by me): PB-700 and PB-1000 character map. The FP-200 uses a reduced version of this map. FX-850P character map. Also valid for VX and Z machines. The character escape sequences for the FX-850P are: AN (Angstroumlm), IN (integral), RT (root), (over), SM (Sum), OM (omega), (gray block), (block), AL (alpha), BT (beta), GA (gamma), EP (epsilon), TH (theta), MU (micro), SI (sigma), P S (psi), S0. S9. S. S-. SN. SX. -1 (superscripts), : (divide), . (dot), DG (deg), gt (greater or equal), lt (less or equal), ltgt (not equal), . V. lt-. - gt (arrows), PI (pi), SP (spade), HT (heart), DI (diamond), CL (club), SQ (square), (circle), TR (triangle). (multiply), PN (pound), CN (cent), -. - (signs), YN (Yen), (backslash, same as Yen). These are not case sensitive: PI and pi are equivalent. The symbolic escape sequences help in porting software from the older PB-100FX-700 series machines and are easier to remember. Just use the - e switch on list730 . Use option - uF if you have created the source text in UTF-8 format. A complete list of the supported extended characters is contained in the following document: CasioFX-850PCharset. pdf With option - eP set on bas850 . a different set of character escapes is used, because the PB-700 and PB-1000 support a different character set. Hexadecimal escapes are not affected by this option. The following codes are used instead (some looking a little strange, like the arrows): 1. 8 (horizontal bars), 1. 7 (vertical bars), (over), (gray block), (block), . (dot), DG (deg), . V. lt-. - gt (sort of arrows), SP (spade), HT (heart), DI (diamond), CL (club), LD (large dot), (circle), TR (triangle), YN (Yen), (backslash). Use option - uP if you have created the source text in UTF-8 format. A complete list of the supported extended characters is contained in the following document: CasioPB700Charset. pdf On the PB-700 and the FX-750P, lines with escape codes beyond 7F cannot be edited because the codes are replaced by their corresponding keywords when using LIST or EDIT. You can still LOAD and RUN such a program. Code F0 (multiplication sign) is not allowed on these machines because it breaks the transmission protocol. It can only be used in the form CHR(ampHF0). Canon X-07 The program supports three output formats: - b creates a binary file, used mainly for debugging the tokenizer or later translation with waveX07. - w creates a WAV file which can be fed to the computer via the sound card. - t creates plain text but all source text translations are performed. The delay value inserts a short break for the slow X-07 and controls the line termination: CR only if a delay is specified, the system default (CRLF for DOS, LF for Unix) without delay. The output can be sent to your machine directly via the serial interface (see below for details.) The Canon X-07 has an extended character set with many special characters for foreign languages like French or German. You can use your favorite editor in DOS or Windows and type text in strings, comments or data lines without worrying about the encoding. If you are on DOS use option - cD. on Windows use option - cW. If your text is in UTF-8 format use option - cU. Escape sequences are supported as well such as :A for Auml or e for eacute. The complete list is in the following document: CanonX-07Token. pdf. You can use binary escape sequences like 86 for Auml. także. A single backslash serves as the marker for an escape sequence. Therefore, in order to enter a backslash for the integer division, you need to encode it as (or YN because it is displayed as the Yen symbol yen on the machine). Using the serial interface on the Canon X-07 to enter a program The Canon X-07 lacks the ability to load an ASCII program with the LOAD command from the serial interface. Instead, it can be remotely controlled from another computer or terminal over the serial line. This way, an ASCII file can be simply typed in from the controlling system. To enable this feature, it is easiest to type in a small program first: The program is now ready to be run from the memory disk with RUNREMOTE. Before you start downloading, make sure to delete the current program. Otherwise, new lines will be merged with existing ones. You can now send your source from the PC. The following example is for a command prompt on Windows: The mode command is necessary only once. The basX07 command assumes that you have entered the text with a windows editor and you want to translate extended characters from Windows to the machines character set. If you see obvious garbage on the display, then the X-07 was too slow to read and store all the lines. You will then need to reduce the speed further or increase the delay after option - t . Turning the machine off and on returns control to the keyboard. An example: Dumping the memory of a PB-770 Here is a short example on how to get the RAM contents of a PB-770 as a binary dump file into your PC. This does not work for the FX-750P or the PB-700 because they lack the necessary PEEK function. Only RAM can be accessed, PEEK does not read out the ROM contents. PEEK(ampH0000) and PEEK(ampH8000) return identical values. PB-770 BASIC source The following source text should be created on the PC and transferred to the PB-770 via sound card: Save the file as pb-dump. txt and translate it to a WAV file: The wav file can now be downloaded to your PB-770. A simple LOAD on the machine will do. Getting the data into your PC Set up your recording software on the PC and start recording. You will need a lot of space. About half of the recording will be silence which you can edit out later if you like. Now run the program and enter the start address and the number of kilobytes to transfer. RAM seems to start at address 0000. Without RAM expansion, the size is 8 kb. Each block of 256 bytes takes about 75 seconds to collect and another 70 seconds to write out. This totals to about 80 minutes for 8 kb of RAM. After the last block has been written, save the recording as a WAV file, lets say as dump. wav . Converting the data The following command converts dump. wav into a readable format: The conversion takes its time because of the size of the WAV file. The file dump. txt can be inspected with an editor or treated with the following simple C program: The filenames dump. txt and dump. bin are hardcoded into the source. Feel free to improve it. The binary file is updated with each run of the program so that you can upload the dump in chunks of your liking. The new data will be inserted or updated in the correct position of dump. bin . Download all files including Windows executable of undump. exe here: mvcsys. dedownloadpb-dump. zip How to handle floppy disk images Creating an image An MD-100 image is a file that contains the sectors of a real 3.5 floppy disk. The disks are written with 80 tracks and 16 sectors of 256 bytes length on each track. Only one side of the disk is used. I use double density disks (without the second hole in the case) but high density disk may work if you cover the hole with black tape. You should format the floppy in the MD-100 drive. Now you need access to a Linux PC. Sorry, I havent written software yet to copy the disk under DOS or Windowsreg. In order to access the disk physically you need to tell the floppy driver about the format of the disk. Ive had success with the package fdutils-5.5 . In the Linux subdirectory of casutil youll find shell scripts to setup the drive, read and write floppies. The setup script makedev. sh creates the device devfd0casio and configures it with setfdprm SS DD ssize256 sect16 . Copying is done with dd . The sample script getmd100.sh creates an image file named md100.img . The md100 program can create an image if you precede the image name by the option - c. It is possible to create disk images of up to 512 blocks instead of the default 320 blocks, but these cannot be written back to a real disk. A new image is filled with empty blocks. The option is mostly ignored if the image already exists but you can increase the maximum allowed size of the image with its parameter. Writing to a floppy The image created in the step above can be written back to a real floppy in pretty much the same way. A sample script putmd100.sh is provided in the linux subdirectory. Manipulating files A single program, md100 . does all the manipulations to the disk image (or the real disk on some operating systems, see below .) Patterns are DOS style, but you can use for all files. Wildcard expansion on local files depends on the platform. On Linux this is automatic, on other platforms it depends on the compiler. The Borland compiler has wildcard support, the library wildargs. obj is automatically linked in by the compile jobs provided with the package. Patterns for files on the floppy must be included in double quotes. MD-100 filenames and types The MD-100 filenames are only eight characters long plus three characters for a file extension. Filenames can contain many characters not allowed on your PC. Case is respected just like on Unix file systems. There are no subdirectories on an MD-100 floppy. Files have an additional attribute, the file type. Both the PB-1000 and the PB-2000C use the file type to select the correct handling of a file selected from the menu. I know of the following types: S - Sequential files, including MEMO files, assembly source files, C data files, files loaded via RS-232C and BASIC programs saved with SAVE, A. Sequential files are opened with the MEMO editor and can be read and written by BASIC or C programs. The contents is ASCII text with CR LF delimiters. R - Relative or Random data files. They can only exist on a disk, not in PB-1000 RAM. C does not use type R files. The contents is defined by the BASIC FIELD statement. M - Machine code files, created by the PB-1000 assembler. B - BASIC programs in internal representation. C - C source or BAT files. The contents is ASCII text with CRLF delimiters, just like sequential files. The PB-2000C can change the file type between C and S from the menu. The PB-1000 misinterprets a type C file and thinks it is a type R file. Consequently it refuses to copy such a file to RAM. There is an additional attribute byte stored in each directory entry on the disk. Bit 0 is used to protect a file. You can set or select the attribute byte with the - p option. Space allocation is done in blocks of 4 sectors (1KB) each. The size in bytes is computed by multiplying the total number of sectors by 256 and searching backwards the last sector of the file for the EOF marker 1A. The marker is added even on empty files. The following examples assume that you have an image named md100.img in the current directory and that the md100 executable is in your path. Listing the disk directory If you want to specify a pattern, the command name dir must be spelled out: The double quotes around the patterns are essential The - i option forces a case insensitive search. You can use the - u or - l options to convert all filenames to upper or lower case. With the options - t andor - p the listing can be restricted to files of a certain type or with a certain protection setting: Listing files Files on the image can be displayed as text with the type command: (Ask me for a complete listing. The authors pages have seemingly gone.) The file name(s) can be patterns and the options - i. - t and - p do also work. If more than one file is specified, each listing is preceded by the filename and a colon. Listings can be binary (hex dump) or ASCII (the default for most file types). You can force a specific listing style with the options - b or - a : As you can see, BASIC programs are decoded from their internal, tokenized form. I cannot guarantee that the decoder works correctly in all cases, save your programs in ASCII from the calculator if you want to be on the safe side Option - e creates the same escape syntax as list850 does. Copying files to the PC The commands get and mget copy single or multiple files from the image to your PC. The only difference is that get just copies one file (in case of a pattern the first that matches) while the second argument is the new name given to the file on your PC. With mget you can copy a bunch of files in one go but your options to rename the files on your PC are limited to a directory name given with the - d option. Both commands allow the file selection options - i. - t and - f and the case conversion options - l and - u . Use get to copy a single file: This will copy the binary file, not the ASCII code of PI. BAS. You can specify no destination at all (defaults to the current directory), an explicit name, a directory ending in or a name ending in . The trailing in the destination filename is replaced by the source file name. If you want an ASCII copy (just like the type command) specify the - a option. Escape syntax can be created with the - e option: If you want to copy multiple files, use mget : The destination (after the - d option) must end in a directory delimiter or . This is prepended (without the trailing ) to the filename from the floppy image. The source filename pattern(s) must be enclosed in double quotes to prevent the shell from interpreting the wildcard characters. Some characters from the source file name are translated to an underscore. Copying files to the floppy image The commands to copy PC files to the floppy image are put and mput . Again, the main difference is that put copies just one file while mput copies a bunch of files in one go. When copying files to the MD-100 image or the floppy, you need to decide which type to assign to the file. The md100 program tries to guess the file type from the extension correctly:.c ..h and. BAT files are of type C..BAS is type B..REL is type R and all others are type S. You can override this with the - t option. The protection attribute is set to 0 by default but can be changed with the - p option. Files saved on your PC with mget in binary mode should be copied back with the - b switch set. This ensures that the file is transferred unchanged to the floppy image. PC text files should be transferred with the - a switch set to ensure ASCII mode. This way, the correct line termination ( CR LF ) is forced on the destination file. ASCII mode is default for all files except types M. R and B. Escape syntax is supported with the - e option, just like in bas850 . If you are unsure whether a copy command will do what you intended, use the option - n before the image name or between the command and its parameters. This prevents updates to the image or the floppy. Use put to copy a single PC file to the image: Since no destination filename was given it was built from the source file. The - u option forces the name to be all upper case. The - e option interprets escape sequences like PI or 80 and translates them to their binary equivalent. The file PI. ASC can later be opened on the PB-1000 with the memo editor or it can be loaded from the BASIC command prompt with LOAD0:PI. ASC. The BASIC interpreter compiles the file to internal format upon loading. You can use piping with the put command if you replace the source filename with stdin or stdin. EXT. Its better to provide a destination filename with a proper extension. Otherwise, the file will be created under the name stdin. EXT . Here is an example: The option - lP of bas850 will translate the fx-850 logarithm syntax LOG LN to the PB-100 syntax LGT LOG . With put and mput . destination names can be patterns included in double quotes. In order to copy all files ending on. asc on your PC to the floppy image and renaming them to be all lowercase and to end on. txt . enter the following command: Note the double quotes around the MD-100 pattern. txt but not around the PC pattern. asc . The third column is the size in blocks. Renaming or deleting files and setting file attributes The commands ren , del and set change the directory of the floppy image. They all work on file patterns or on single files. To rename all BASIC files to lower case with the extension. bas use the following command: As usual, all patterns must be enclosed in double quotes. With the ren command, all patterns except the last are considered source files, the last pattern forms the new name(s). To delete some C files from the image, enter: Use option - tC and the pattern to delete all type C files. To change all type C files to be of type S and alter the protection attribute, enter: This allows access to the files created by the PB-2000C from a PB-1000. The protection attribute is supposed to protect the file against writing. Direct floppy access On Linux, you can replace the image name in the md100 commands by devfd0casio . the device created with makedev. sh. All operations are directly performed on the floppy. Thats much slower than manipulating an image but you save the work of copying the image back and forth. On Windows youll need an additional package, LibDsk. This is a library to directly access floppies in various formats. See the file readme. txt in the win32 subdirectory. The library is cross platform and it should be perfectly possible to use it on other platforms. I simply havent tried it, yet. You can set the - DLIBDSK switch of your C compiler and try for yourself. To access the floppy, replace the image name with A: . Ive written an OS2 floppy access module as well, but that doesnt work, I keep getting read errors. My interest in OS2 has ceased so updates are unlikely. -( BASIC Comparison Sheet Ive made an attempt to compare the various BASIC dialects of different pocket computers in tabular form: Download page. The link points to the online version of the download page, a local copy is part of this package. The comparison includes Casio, Sharp, HP, TI, Canon and Epson machines. Casio Pages The following Internet sites have more or less influenced my work. More links can be found on these pages. Piotr Piatek has inspired much of what you can find here. Some recent bug fixes and contributions, e. g. direct floppy access from DOS, are by him. He has a deep insight in Casio hardware and has even built the interfaces himself. Visit his site at pisi. plpiotr433index. htm Ledudus site, dedicated to Casio calculators and pocket computers, with many pictures and links: ledudupockets. asp (English and French). Information about the PB-700 can be found on the pages of Christophe le Glatin, now hosted by Ledudu: casio. leduducasiopb700casiopb700.htm. Some French r equired. Thomaacutes Wrobel has collected technical information about the PB-1000: itkp. uni-bonn. de Viktor Toths rskey. org is a site that deals with many programmable calculators, among them several Casio models: rskey. org . The Pocket Computer Museum has many pictures and technical data. It hosts some software for Sharp pocket computers: pocket. free. frindex. html . SilRun Systems (Silent Runner) hosts many scanned Casio manuals: silrun. de . Manfred Becker has created a USB interface and a BASIC program editor for the FX-850P and its successors: manib. ma. funpic. dedetaschenrechner. htm (German pages only). The various file formats of Casio graphics calculators are the topic of the Casio file format documentation project. casetta. tuxfamily. orgformats . Casios communication software FA-124 can be downloaded here: world. casioeduresourcesfa124 Floppy access LibDsk . the library used to access the floppy to manipulate MD-100 disks is written by John Elliot: seasip. demon. co. ukUnixLibDsk . The auxiliary Windows driver fdrawcmd that LibDsk uses is the work of Simon Owen: simonowenfdrawcmd . Contact: Marcus von Cube ltmarcusmvcsys. de gt Page last updated: March 15, 2018

No comments:

Post a Comment